WScript.Shell

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

My question is simple: I have to use the WScript.Shell object from VBA
(Excel 2000), but i want to use early-binding (instead of
late-binding--> CreateObject("WScript.Shell")).

I'm unable to find out what reference I must to set in the VBA editor
in order to use that object.

Thank you beforehand.
 
Try: "Windows Script Host Object Model"

c:\windows\system32\wshom.ocx

--
Jim
| Hi,
|
| My question is simple: I have to use the WScript.Shell object from VBA
| (Excel 2000), but i want to use early-binding (instead of
| late-binding--> CreateObject("WScript.Shell")).
|
| I'm unable to find out what reference I must to set in the VBA editor
| in order to use that object.
|
| Thank you beforehand.
|
 
Thank you for replying.

I've already tried that library. But my code still doesn't compile:

Dim wsh As WScript.Shell
Set wsh = new WScript.Shell
 
I think that library will work:

Sub test()
Dim wsh As WshShell
Set wsh = New WshShell
wsh.Popup "hi"
Set wsh = Nothing
End Sub

-John Coleman
 
I also think so.

Thank you.

John Coleman said:
I think that library will work:

Sub test()
Dim wsh As WshShell
Set wsh = New WshShell
wsh.Popup "hi"
Set wsh = Nothing
End Sub

-John Coleman
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top