Jump to content
Sign in to follow this  
rajeshontheweb

ShutdownDialog - Invoke standard Shutdown dialog box

Recommended Posts

rajeshontheweb

_ShutDownDialog()

Func _ShutDownDialog()
; Rajesh V R 
; An Undocumented dll function, thanks to nirsoft for revealing it... (and all those who posted it on google!)

       ShellExecute("rundll32.exe","shell32.dll,#60")
EndFunc

this opens a standard shutdown dialog box for windows

Posted Image

Edited by rajeshontheweb

Share this post


Link to post
Share on other sites
rajeshontheweb

yeah i did search for it in the forums, thought it might have been posted as a dllcall or something, but this wasnt found. so posting it here for anyone who would like it. because, personally i have searched for this functionality earlier.

and rather than closing progman, or shell object, this would be preferrable ?

Edited by rajeshontheweb

Share this post


Link to post
Share on other sites
youknowwho4eva

It's bugging me because I'd swear I'd seen it before. But yes personally I'd prefer your method. I've seen computers where stopping processes doesn't do what you expect 100% of the time.


Giggity

Share this post


Link to post
Share on other sites
rajeshontheweb

guys, just found another way of triggering shutdown dialog

this uses the Shell.application (thought it might be useful for cases where u are dealing with shell application object already and may not need to use shellexecute call seperately..

Dim $ObjShell
$ObjShell = ObjCreate("Shell.Application")
$ObjShell.ShutdownWindows()
$ObjShell = ""
Edited by rajeshontheweb

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×