Jump to content
Sign in to follow this  
billthecreator

Open As Dialog?

Recommended Posts

billthecreator

is there a way to call a DLL of open as?

i saw somewhere, either VB or C, that they use the verb, "openas" in their

shell execute. but that didn't work with autoit's shellexecute.


[font=Microsoft Sans Serif]My Scripts: From Most recent to least.[/font]Countdown GUI | QLOCK TWO | FlipClock | Slot Machine My UDF:_GenerateRandomNoRepeat | _GuiSnap

Share this post


Link to post
Share on other sites
Inverted

Do you mean the undocumented verb "runas" which, according to some comments, requests UAC elevation :

http://msdn.microsoft.com/en-us/library/bb762153%28VS.85%29.aspx

Would be interesting if someone with UAC enabled would try it and report back :D

Share this post


Link to post
Share on other sites
spudw2k

_OpenWith(FileOpenDialog("","","All Files (*.*)"))

Func _OpenWith($file)
    If FileExists($file) Then Return DllCall("shell32.dll","hwnd","OpenAs_RunDLL","hwnd",0,"str","","str",$file, "int", 0)
EndFunc

Edited by spudw2k

Share this post


Link to post
Share on other sites
billthecreator

_OpenWith(FileOpenDialog("","","All Files (*.*)"))

Func _OpenWith($file)
    If FileExists($file) Then Return DllCall("shell32.dll","hwnd","OpenAs_RunDLL","hwnd",0,"str","","str",$file, "int", 0)
EndFunc

I believe this is what im looking for. Im at work right now, will have to try it later.

Thank you so much.


[font=Microsoft Sans Serif]My Scripts: From Most recent to least.[/font]Countdown GUI | QLOCK TWO | FlipClock | Slot Machine My UDF:_GenerateRandomNoRepeat | _GuiSnap

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  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.