• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 669
  • Last Modified:

Open UI with VBScript

I am tasked with opening a modal UI (a UI which must have a user click a selection to continue) which is not viewable by the user at the console. This is for testing a piece of software to see how it responds to a spawned UI which cannot continue.
It was suggested I use the Shutdown command, but I am unsure how to call it from within VBScript.

Thanks for your help!
JohnD
0
John Darby
Asked:
John Darby
  • 2
1 Solution
 
gecko_au2003Commented:
shutdown command of windows ?

http://www.burzurq.com/forum/shutdown_icon.html

If thats the case then this should suffice in vbscript :

Set WshShell = CreateObject("Wscript.Shell")

WshShell.Exec "C:\WINDOWS\RUNDLL32.EXE shell32,SHExitWindowsEx 1"

If that does not work then use the .Run command of WshShell ie

WshShell.Run "C:\WINDOWS\RUNDLL32.EXE shell32,SHExitWindowsEx 1"

obviously you have to make sure the path to RUNDLL32.EXE is in the right path otherwise the above wont work.

Thanks
0
 
John DarbyPMAuthor Commented:
Thanks Gecko!
0
 
gecko_au2003Commented:
your welcome :) let me know if it works
0

Featured Post

[Webinar] Cloud and Mobile-First Strategy

Maybe you’ve fully adopted the cloud since the beginning. Or maybe you started with on-prem resources but are pursuing a “cloud and mobile first” strategy. Getting to that end state has its challenges. Discover how to build out a 100% cloud and mobile IT strategy in this webinar.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now