Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

VBScript Global 'Err' Available in Win32::OLE

by thartman@mst.edu (Initiate)
on Nov 04, 2014 at 18:19 UTC ( [id://1106081]=perlquestion: print w/replies, xml ) Need Help??

thartman@mst.edu has asked for the wisdom of the Perl Monks concerning the following question:

Is the VBScript/VB global variable Err accessible in Win32::OLE?

I'm invoking a function (e.g. SWbemServices.ExecQuery) that sets a global variable.

In my case, I'm executing a WQL query. When I give it bad SQL/WQL, Win32::OLE->LastError() doesn't seem to contain any indication of that. The Win32::OLE docs don't say anything about the source of LastError(), only that it's the last error set.

Does anyone know if Err is available through Win32::OLE?
  • Comment on VBScript Global 'Err' Available in Win32::OLE

Replies are listed 'Best First'.
Re: VBScript Global 'Err' Available in Win32::OLE
by Loops (Curate) on Nov 04, 2014 at 20:33 UTC

    Hi There, and welcome to the monastery.

    I'm slightly dumbstruck, but took a quick look on Microsoft site and see they have a Perl example of how to get the last SWbemServices error... Microsoft Perl example. Of course the bastards make you scroll to the bottom of the page. ;o)

    HTH.
      It never occurred to me to look for Perl on their web site. I am completely shocked. Thanks.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://1106081]
Approved by ww
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (3)
As of 2024-04-26 02:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found