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 dencom on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Not getting all tte data......Sometimes?

Status
Not open for further replies.

papollo

Programmer
Oct 19, 2001
71
US
Hello:

At work, each morning we receive large amount of data from banks via ProComm Plus 32. A aspect script is executed from a winbatch script.

80% of the time we get all the bank data.
20% The ProComm runs, I can see the data coming across on the screen then the ProComm script ends. The file never gets processed because it is missing trailer data info.

Here is a copy of the script.
Disclaimer: I did not write this script.


;
;Recorded script. Editing may be required.

proc main

set modem connection "U.S. Robotics 56K Voice INT PnP"

;Set xmodem overwrite ON
;Set terminal rxcr CR_LF
Set duplex full
clear
locate 0 0

dialnumber DATA "XXXXXXXXXXXXXXXX"

Set capture autostart ON
Set Capture Overwrite On
Set capture recordmode SCREEN
Set Capture file "XXXXXXX.txt"
waitfor "please type your terminal identifier"

If failure
Hangup
PWexit
EndIf

transmit "O"
waitfor "please log in: "
transmit "XXXXXXXX^M"
waitfor "password: "
transmit "XXXXXXXXXXX^M"
waitfor " =====> "
transmit "connect^M"
waitfor " ^M"
transmit "XXXXXXXXXX^M"
waitfor "IIIIIIIIIIIIIIIII ^M"
transmit "XXXXXXXXXXXX^M"
waitfor "99 ACF2/CICS SIGN-ON COMPLETE^M^J^M^J^M^J^J"
transmit "mcon^M"
waitfor "ELP END BRSTAT BALPBX^M^J"
transmit "balpbx^M"
waitfor "NTER DATE (MMDDYY) OR `"STATUS`"^M^J"
transmit "^M"
waitfor "TANDARD OPTIONS (Y OR N)^M^J"
transmit "^M"
waitfor "NTER SELECTION CRITERIA (BANK= OR ACCT=)^M^J"
transmit "^M"
waitfor "NTER TRANSMISSION FORMAT (B--FOR BALANCES, D--FOR BALANCES + DETAIL)^M^J"
transmit "d^M"
waitfor "NTER MINIMUM AMOUNT FOR ACCUMULATION (999.99)^M^J"
transmit "^M"
waitfor "LEASE DEPRESS YOUR CAPTURE KEY TO BEGIN TRANSMISSION^M^J"
transmit "^M"
waitfor "RANSMISSION COMPLETE -- PLEASE PRESS THE RETURN KEY^M^J"
transmit "signoff^M"

Hangup
pwexit

endproc

 
One thing I would do is pare down some of the strings in the waitfor commands. If these strings are longer than necessary, a glitch in the transmission (such as line noise) would have a better chance of garbling the string and throw off your script.

Is your script supposed to save the information to a file, or are you only viewing it on screen? I see some capture statements in your script, but nowhere that a capture file is actually opened and closed, unless you have associated this script with an entry in the Connection Directory. If you are dialing from the Connection Directory, then I would remove the dialnumber command as it is not needed.
 
Ok

I am a real novice with Aspect.

I replaced secure info with XXXXXXX. I did not want the passwords and such to be on forum.
The waitfor's are used to respond to things like password and signon and etc.

Yes the script does save the information to a file.

The script is not using the Connection Directory. that is why the dialnumber statement is used.

Is there a timer or count I can setup in the script to wait so many seconds before closing the script?

Thanks for your help.
 
I would add the lines:

while $DIALING
endwhile

after your dialnumber command. Without these commands, your first waitfor command could timeout before being connected to the site, which would most likely result in an empty capture file.
 
Thank you

One last question:

I insert the while $dialing after the dialnumber and then I put the endwhile at the end of the script. Is that correct?
 
No, the endwhile would be immediately after the while $DIALING line. This keeps the script in a "paused" state until the modem has finished dialing the other computer. Once the dialing process is done and the machines have successfully connected, then your script will continue on.
 
Thanks. I will place the code in the script and test it.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top