Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Awaiting text on display 1

Status
Not open for further replies.

stuwarf

IS-IT--Management
Apr 25, 2005
1
US
In the following code the subroutine "pexit" is never called, even though the "quit DISPATCH" string shows up on the display. I'm using VT100. Essentially what I am trying to do is to have the sendvkey string sent (which is recognized as a "go back one screen" in the application) until the "home" screen (containing "quit DISPATCH") appears. Is there a better way to do this? Why is the target screen not recognized by this script?

Code:
proc main
	when target 0 "quit DISPATCH" call pexit

   while 1
   	sendvkey 0x78
  	endwhile
endproc

proc pexit
	usermsg "Target Found"
	exit
endproc
 
Chances are there is an escape sequence or another terminal emulation string that is in the text you are searching for (i.e. bolding, positioning code, etc.). You can check this by using the Monitor Window. Here is some code I copied from my site with more information:

Procomm's Monitor Window can be used to view the incoming and outgoing data, in both hex and ASCII format. To activate this window, select the Data | Monitor Window menu item. Resize the Monitor Window so that you can view the entire width of the window, then click back in the Procomm Plus window so that the Monitor Window does not have focus. Incoming text is displayed in red, while text you send is colored blue. The Monitor Window can be handy for viewing incoming escape sequences (to determine if Procomm Plus is responding properly to them) or to verify that the program is sending the data you think it should be.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top