AllExperts > Experts 
Search      

VB Script

Volunteer
Answers to thousands of questions
 Home · More Questions · Answer Library  · Encyclopedia ·
More VB Script Answers
Question Library

Ask a question about VB Script
Volunteer
Experts of the Month
Expert Login

Awards

About Us
Tell friends
Link to Us
Disclaimer

 
 
 
 
About Miguel Zapico
Expertise
I can answer question about how to use scripts to consolidate data, connect different systems and automate tasks. I have no experience on using VBScript on web programming.

Experience
I have been using VBScript and Windows Scripting Host as my swiss tool for the last 6 years.

Organizations
New York PC users group (NYPC)
Independant Computer Consultants Association (ICCA)

Education/Credentials
Microsoft MCSE in Windows NT

 
   

You are here:  Experts > Computing/Technology > Basic > VB Script > VBA

Topic: VB Script



Expert: Miguel Zapico
Date: 7/24/2006
Subject: VBA

Question
I have declared an object variable for a class and instantiated. When a use a method available in the declared Class of the object variable, it gives an error message saying GET Method Failed.

Let me attach the code and the error message here with this mail below.

Dim Temp As XSCRIPTINGHOSTLib.ScriptItemDialog

-------------------------------------------------

Sub EntryLevelMacro()

Set Temp = New XSCRIPTINGHOSTLib.ScriptItemDialog

Temp.MessageBox "Info", "Show this message"

Set Temp = Nothing

End Sub

-------------------------------------------------


Error Message :

Run-time error '2147220604(80040384)':

Method 'MessageBox' of object 'IScriptItemDialog' failed

Answer
Sorry, I don't have that object on my system.  What application is it refered to?

Also, what is the context where you are programming?  For example, in VBA there is a msgbox function that can do what you need:

Sub EntryLevelMacro()
  MsgBox "Show this message", , "Info"
End Sub

Miguel.

Add to this Answer    Ask a Question



  Rate this Answer
   Was this answer helpful?
Not at allDefinitely              
   12345  

     
About Us | Advertise on This Site | User Agreement | Privacy Policy | Help
Copyright  © 2008 About, Inc. About and About.com are registered trademarks of About, Inc. The About logo is a trademark of About, Inc. All rights reserved.