/build/static/layout/Breadcrumb_cap_w.png

how to pass input message text as a parameter with other exe.

I want a bat script, which is required input message text as a parameter, append with other exe.

I have a exe. Client require launch this exe with dynamic parameter. This dynamic parameter should type end user (input message).

Please help me..

suppose: i have abcd.exe and parameter is "APACDBPRD1", It should launch "abcd.exe APACDBPRD1"


0 Comments   [ + ] Show comments

Answers (2)

Posted by: SMal.tmcc 10 years ago
Red Belt
1

ok if I understand you. 

As an example I want people to enter a file name to open in notepad automatically via a batch file. 

I would use

@echo off
set /p xx="Enter file to run in notepad: " %=%
notepad %xx%

the windows pops up and asks me the question and I type in c:\test1.txt and hit enter

Posted by: anonymous_89149 10 years ago
Yellow Belt
0

I've used AutoIt to do this previously. (http://www.autoitscript.com/site/autoit/)

eg

............................................................................................................. 

Local $Arg1 = InputBox("Get Arguement for my exe", "Please enter the required arguement.", "APACDBPRD1")
if @Error=1 Then
   Exit
EndIf

ShellExecuteWait("ABCD.exe", $Arg1)

..............................................................

 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ