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

When Target (will not compile)

Status
Not open for further replies.

TheMoogy

IS-IT--Management
Jan 15, 2003
35
GB
When I compile a aspect script with the following line:

when TARGET 0 ":" call getprompt

I get message saying "Invalid number of arguments"

As far as I can tell the syntax is correct?

Any ideas?

Cheers

Matt
 
Matt, that is the correct syntax, and it compiled OK on my machine. Does the code immediately above that line look correct? I'm wondering if the compiler is encountering problems in the line above and it is showing up in the line you posted instead. aspect@aspectscripting.com
 
Looks like it was the line above. Not sure what was wrong with it, but have managed to get it to work.

Is there anyway to send variables along with the call, such as "call with var1, var2" but still using "when target"

Cheers
Matt

 
According to the help on WHEN statements (Procomm 4.7) the call "The called procedure must not require any parameters."
I also have found that while a function can be used in place of a procedure no value can be received back into the WHEN statement call.

If there is any way to do these things I am also interested.

I guess all that can be done otherwise is use GLOBAL variables.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top