WinBatch Tech Support Home

Database Search

If you can't find the information using the categories below, post a question over in our WinBatch Tech Support Forum.

TechHome

Serial
plus

Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.

Serial Extender, Timeouts and BoxText

Keywords:     Timeouts

Question:

I'm having problems with the timeout values. It seems so straightforward, but I'm obviously doing something wrong. My state list times out in California after just a few seconds. I thought I set the timeout value to 2 minutes! The list should go clear through to Wyoming.

Here's part of my code...

------------------

pPutLine(port,"1") 
RetCode = pWaitFor(port,"choice !","+",0,3000)
If RetCode == 0 Then goto Abort
BoxText("1 for List")

pPutLine(port,"1") 
RetCode = pWaitFor(port,"=No:","+",0,120000)
If RetCode == 0 Then goto Abort
BoxText("1 for List by State")

pPutLine(port,"Y") 
RetCode = pWaitFor(port,"Dallas","+",0,120000) ;timeout is 2 minutes! Dallas is just a test.
If RetCode == 0 Then goto Abort
BoxText("States being listed...")

goto NormalEnd

:Abort
BoxText("Run aborted...")
goto eoj

---------------
I'm also curious as to the placement of the BoxText command. It seems that I need to place it AFTER the real code rather than BEFORE it for it to show what's really happening. Where is the documentation for the BoxText command?

Also, is there a way I could watch what's happening in real time (like in Hyperterminal) rather than just going to my browser output after the fact? That would sure be nice.

Answer:

  1. BoxText placement is generally before the operation it describes. It is documented in the SMALL manual and also in the WINBATCH.HLP file (not the WIL help file).

  2. Timeouts look OK. Try bigger values? Values up to 1000000 are legal. There may be a conversion problem someplace, but I looked and it seemed OK.

  3. Sorry, no real time looks, but add some pCaptureLog("text") statement to your code to write debugging info to the capture file as you go...

Article ID:   W12578
Filename:   Serial Extender - Timeouts - Boxes Functions.txt
File Created: 1999:04:15:16:48:12
Last Updated: 1999:04:15:16:48:12