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

thread99-1769215 I have a si

Status
Not open for further replies.

LizzyBigDitch

Technical User
Mar 7, 2008
1
GB
thread99-1769215



I have a similar problem with this demo example.

Dim ReturnValue, I
ReturnValue = Shell("CALC.EXE", 1) ' Run Calculator.
AppActivate ReturnValue ' Activate the Calculator.
For I = 1 To 100 ' Set up counting loop.
SendKeys I & "{+}", True ' Send keystrokes to Calculator
Next I ' to add each value of I.
SendKeys "=", True ' Get grand total.
SendKeys "%{F4}", True ' Send ALT+F4 to close Calculator.



I created a .vbs file and it errors as follows:
Line: 6
Char: 6
Error: expected end of statement

If anyone has the code to do this or something similar I would be very grateful
 
Hi,

You've been around since 2008 without a peep, so welcome back.

You're posting in a forum about Attachmate VB using Microsoft VBA code.

So which is it?

Skip,
[sub]
[glasses]Just traded in my OLD subtlety...
for a NUance![tongue][/sub]
"The most incomprehensible thing about the universe is that it is comprehensible" A. Einstein
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top