|
|
|||||||||
|
|||||||||
|
|||||||||
| |
||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
How can i use lpParameters in Shellexecute()?
hello guys
i am trying to write a program that executes a shell program like oracle Export, as you know for that kind of programs parameters is important, for example i have to do it with userid and Password also i want to change a password for example when a user typed my programs name in cmd and add userid and password and db_name, i want to change that password and send it to oracle i tried with shellexecute() but i couldnt use lpParameters how can i use lpParamaeters? somebody can help me?! this is urgent. my email address is info@fatihnayebi.com or f.nayebi@gmail.com this is my program Module Module1 Dim extra As String Sub Main() ShellExec() End Sub Public Declare Function ShellExecute _ Lib "shell32.dll" _ Alias "ShellExecuteA" ( _ ByVal hwnd As Long, _ ByVal lpOperation As String, _ ByVal lpFile As String, _ ByVal lpParameters As String, _ ByVal lpDirectory As String, _ ByVal nShowCmd As Long) _ As Long Sub ShellExec() Dim strFile As String Dim strAction As String Dim lngErr As Long Dim Usr_param As String Dim Pass_param As String Dim parametre As String Dim lpparameteres As String Dim parfile As String extra = "x" parfile = "jksdfkasj" Console.WriteLine("Please enter your user name ") Usr_param = Console.ReadLine Console.WriteLine("Please enter your password") Pass_param = Console.ReadLine() Pass_param = Pass_param + extra 'parametre = "userid=" & Usr_param & "/" & Pass_param & "@symphony " & parfile strFile = "R:\oracle\product\10.1.3\Db_1\BIN\exp" strAction = "OPEN" lngErr =ShellExecute(0, strAction, strFile, parametre, "", 0) End Sub End Module |
|
#2
|
|||
|
|||
|
lpParameters is what is added to "the command line" of the application, your app must be able to cope with them.
like notepad file.txt And, as far as I know, the parameters must be with chr(34) at the begining and end of the text (this includes lpfile, lpparameters and lpdirectory). |
![]() |
| Viewing: ASP Free Forums > Programming > Visual Basic Programming > How can i use lpParameters in Shellexecute()? |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|