1. Kobi Hasson
  2. PowerBuilder
  3. Tuesday, 21 December 2021 08:26 AM UTC

In the following code, The line: "var eof = exe.StdOut.AtEndOfStream;" hangs, and the PB program does not exit.

 

Please create file b.wsf with the following content, and run it by:  cscript  b.wsf

// As a result, the line: "var eof = exe.StdOut.AtEndOfStream;" hangs.

// And the program test2019.exe (which is an empty PB program built and run in PB2019

// environment) also hangs and never exits.

 

<job id="Job1">

<script language="JavaScript">

 

var shell = new ActiveXObject("WScript.Shell");

var exe = shell.Exec("test2019.exe 2>&1");

var eof = exe.StdOut.AtEndOfStream;

WScript.StdOut.Write("hi…");  // this line is never executed since the previous line hangs.

 

</script>

</job>

 



There are no replies made for this question yet.
However, you are not allowed to reply to this question.
We use cookies which are necessary for the proper functioning of our websites. We also use cookies to analyze our traffic, improve your experience and provide social media features. If you continue to use this site, you consent to our use of cookies.