UGN Security
Posted By: Ntd Openning apps. - 10/08/03 10:52 AM
Does anyone know how to open apps from vb?
Posted By: BackSlash Re: Openning apps. - 10/09/03 01:50 AM
i take it to mean you want to be able to open other programs from your program. if so, you use Shell(). for instance, if you wanted to open up notepad you would do Shell("C:\windows\notepad.exe") hope that helps
Posted By: Ntd Re: Openning apps. - 10/09/03 03:25 AM
Thanks Mate!!!!!!!!!!!!!!!! thats what i wanted to do!!!!!!!
Posted By: Ntd Re: Openning apps. - 10/09/03 05:20 AM
One more thin how do set parameters eg for ie, how do u make it open ie at a certain website?
Posted By: SilentRage Re: Openning apps. - 10/09/03 09:21 AM
Include the commandline parameters in the Shell string like so:

Shell("C:\Program Files\Internet Explorer\iexplore.exe http://serialcoders.sytes.net")

In case there's confusion with commandline arguments and the path you can add double quotes:

Shell("""C:\Program Files\Internet Explorer\iexplore.exe"" http://serialcoders.sytes.net")
Posted By: Ntd Re: Openning apps. - 10/10/03 05:45 AM
Shell (File1.Path & File1.FileName)
Why doesn't it work?
Posted By: SilentRage Re: Openning apps. - 10/10/03 06:52 AM
I don't know. I have no idea what "File1" is.
Posted By: bosky101 Re: Openning apps. - 10/10/03 01:30 PM
can u say..open an app and send keystrokes as default values as well...like sending to a programs log in .to make it an auto login ?
Posted By: SilentRage Re: Openning apps. - 10/10/03 04:25 PM
yes, but there's easier ways to do that.
Posted By: alchemist Re: Openning apps. - 10/14/03 09:29 AM
Quote:
Originally posted by NTD .:
Shell (File1.Path & File1.FileName)
Why doesn't it work?
Shell (File1.Path & "\" & File1.FileName)
you can always debug.print File1.Path & "\" & File1.FileName
and see what its actually outputting...

also to send keys: sendkeys "{enter}"
or sendkeys "{home}+{end}"
sendkeys "abcd"

'Backspace {BS}
'Break {BREAK}
'Caps Lock {CAPSLOCK}
'DELETE {DEL}
'Down Arrow {DOWN}
'END {END}
'ENTER {ENTER} or ~
'Escape {ESC}
'Help {HELP}
'Home {HOME}
'Insert {INS}
'Left Arrow {LEFT}
'Num Lock {NUMLOCK}
'Page Down {PGDN}
'Page Up {PGUP}
'Print Screen {PRTSC}
'Right Arrow {RIGHT}
'Scroll Lock {SCROLLLOCK}
'Tab {TAB}
'Up arrow {UP}
'F1 - F16 {F1} - {F16}
'Shift +
'Ctrl ^
'Alt %
Posted By: BackSlash Re: Openning apps. - 10/15/03 01:52 AM
ntd, it should be Shell(file1.path & "\" & file1.filename)

you forgot the backslash in the middle. also, you have to make sure a file is actually selected in the file list box.
Posted By: alchemist Re: Openning apps. - 10/17/03 04:32 PM
ahh...isnt that what i just said? o_O
© UGN Security Forum