bWaitOnReturn redux: I have the error msg 
Author Message
 bWaitOnReturn redux: I have the error msg

To Michael Harris:

Thanks for the response to my 11/25 post on using the bWaitOnReturn
option for the RUN method of WshShell.

I still encounter a problem in this line of script:

WSHShell.Run("c:\unzipped\ScriptIt c:\unzipped\script1.INI", 1, TRUE)

If I remove the two optional arguments, the script runs fine, as
follows:

WSHShell.Run("c:\unzipped\ScriptIt c:\unzipped\script1.INI")

Again, the problem is that the loop this is contained in runs every
minute--I'm getting a new ScriptIT session each minute, instead of
having the script wait until the event occurs that I want to act on.

Here is the compilation error msg:

"Cannot use parentheses when calling a Sub" -- Code 800A0414

The indication point for the error is after the last parentheses in the line.

Any help appreciated.

Tom Herlihy



Sat, 17 May 2003 03:00:00 GMT  
 bWaitOnReturn redux: I have the error msg
If you are returning a value from a function, use parenthesis around
the parameters.  If you are simply calling, without returning a value,
then list the parameters without the use of parenthesis.

In the code snippet you provided, it does not look like you are using
the return value, therefore you should omit the parenthesis.

--
______________________________________________________________________
Lee Gillie, CCP                                Remove NOSPAM to E-Mail
Online Data Processing, Inc. - 3501 N. Haven -  Spokane, WA 99207-8500

Quote:
> Here is the compilation error msg:
> "Cannot use parentheses when calling a Sub" -- Code 800A0414
> The indication point for the error is after the last parentheses in the

line.


Sat, 17 May 2003 03:00:00 GMT  
 bWaitOnReturn redux: I have the error msg


Quote:
> If you are returning a value from a function, use parenthesis around
> the parameters.  If you are simply calling, without returning a value,
> then list the parameters without the use of parenthesis.

... or prefix all with a CALL:

   CALL  WSHShell.Run("c:\unzipped\ScriptIt c:\unzipped\script1.INI"", 1,
TRUE)

/Al

Quote:
> In the code snippet you provided, it does not look like you are using
> the return value, therefore you should omit the parenthesis.

> --
> ______________________________________________________________________
> Lee Gillie, CCP                                Remove NOSPAM to E-Mail
> Online Data Processing, Inc. - 3501 N. Haven -  Spokane, WA 99207-8500

> > Here is the compilation error msg:
> > "Cannot use parentheses when calling a Sub" -- Code 800A0414
> > The indication point for the error is after the last parentheses in the
> line.



Sat, 17 May 2003 03:00:00 GMT  
 bWaitOnReturn redux: I have the error msg
Many thanks to you both--I guess this shows what a newbie I am in
writing  this code-it is a wonderful environment, but I guess I have a
few things to learn!!

Tom H
===========================================

Quote:



> > If you are returning a value from a function, use parenthesis around
> > the parameters.  If you are simply calling, without returning a value,
> > then list the parameters without the use of parenthesis.

> ... or prefix all with a CALL:

>    CALL  WSHShell.Run("c:\unzipped\ScriptIt c:\unzipped\script1.INI"", 1,
> TRUE)

> /Al

> > In the code snippet you provided, it does not look like you are using
> > the return value, therefore you should omit the parenthesis.

> > --
> > ______________________________________________________________________
> > Lee Gillie, CCP                                Remove NOSPAM to E-Mail
> > Online Data Processing, Inc. - 3501 N. Haven -  Spokane, WA 99207-8500

> > > Here is the compilation error msg:
> > > "Cannot use parentheses when calling a Sub" -- Code 800A0414
> > > The indication point for the error is after the last parentheses in the
> > line.



Sun, 18 May 2003 03:00:00 GMT  
 bWaitOnReturn redux: I have the error msg
The EXE links are downloads of the complete documentation sets in HTMLHelp format - highly
recommended for offline use.  The Tutorial/User's Guide content is also included in the downloaded
documentation...

WSH 2.0 Tutorial
http://msdn.microsoft.com/scripting/windowshost/doc/wsTutorialTOC.htm
WSH Documentation
http://msdn.microsoft.com/scripting/windowshost/docs/reference/defaul...
http://msdn.microsoft.com/scripting/windowshost/wshdoc.exe

VBScript User's Guide
http://msdn.microsoft.com/scripting/vbscript/doc/vbstutor.htm
VBScript Documentation
http://msdn.microsoft.com/scripting/vbscript/techinfo/vbsdocs.htm
http://msdn.microsoft.com/scripting/vbscript/download/vbsdoc.exe

FileSystemObject User's Guide
http://msdn.microsoft.com/scripting/vbscript/doc/jsFSOTutor.htm
VBScript Run-Time Library Reference [FileSystemObject/Dictionary]
http://msdn.microsoft.com/scripting/vbscript/doc/VBSFSOTOC.htm

JScript User's Guide
http://msdn.microsoft.com/scripting/jscript/doc/jsconJScriptUsersGuid...
JScript Documentation
http://msdn.microsoft.com/scripting/jscript/techinfo/jsdocs.htm
http://msdn.microsoft.com/scripting/jscript/download/jsdoc.exe

WSC Tutorial
http://msdn.microsoft.com/scripting/scriptlets/doc/lettitle.htm
WSC Documentation
http://msdn.microsoft.com/scripting/scriptlets/serverdocs.htm
http://msdn.microsoft.com/scripting/scriptlets/wscdoc.exe

--
Michael Harris
Microsoft.MVP.Scripting
--

Please do not email questions - post them to the newsgroup...
--

Quote:

> Many thanks to you both--I guess this shows what a newbie I am in
> writing  this code-it is a wonderful environment, but I guess I have a
> few things to learn!!

> Tom H
> ===========================================



> > > If you are returning a value from a function, use parenthesis around
> > > the parameters.  If you are simply calling, without returning a value,
> > > then list the parameters without the use of parenthesis.

> > ... or prefix all with a CALL:

> >    CALL  WSHShell.Run("c:\unzipped\ScriptIt c:\unzipped\script1.INI"", 1,
> > TRUE)

> > /Al

> > > In the code snippet you provided, it does not look like you are using
> > > the return value, therefore you should omit the parenthesis.

> > > --
> > > ______________________________________________________________________
> > > Lee Gillie, CCP                                Remove NOSPAM to E-Mail
> > > Online Data Processing, Inc. - 3501 N. Haven -  Spokane, WA 99207-8500

> > > > Here is the compilation error msg:
> > > > "Cannot use parentheses when calling a Sub" -- Code 800A0414
> > > > The indication point for the error is after the last parentheses in the
> > > line.



Sun, 18 May 2003 03:00:00 GMT  
 
 [ 5 post ] 

 Relevant Pages 

1. Error Msg

2. HELP- ghostscript couldn't start with a fatal error msg

3. Error msg when running Cscript

4. bwaitonreturn

5. "bWaitOnReturn" option for WshShell.Run method

6. PostScript Calendars redux

7. Code Parsing Redux - stateless regex-based subtractive tokenizing

8. Code Parsing Redux - stateless regex-based subtractive tokenizing

9. Ghostscript: eps->tiff fails w/o err msg

10. URGENT MSG

11. How to show a msg on status line- for a button

12. msg.wsc

 

 
Powered by phpBB® Forum Software