1.

Solve : help creating shortcuts using parameters?

Answer»

Hi
I need to call multiple shortcuts from a single batch file using parameters
Someone help me plz
thanks!!give examples of what you have done so far and also please describe more fully what you want to do.
here's what i have done so far but i have problem working with parameters

echo off
echo H:\logthis.BAT
Rem Create the Batch PROGRAM containing the Prompt Command
Echo @Prompt $D $T > MakeProm.bat
Rem Execute the Prompt command and add the results to the log file
command /c MakeProm.bat >> "h:\LogJob.log"
rem run the program to view parameters

if not "%1"=="" %1
echo %2
echo%3


pause



[recovering space - attachment deleted by admin]What has all this got to do with the picture?
well i created shortcut from the batch file and i target it to run the application for example EXCEL
cuz i need to call the batch program from numerous shortcuts, passing the program title and file name as parameterso what is that makeprom.bat for?
is to record the time date and the title of the application that has been lunched and save into a txt file "LogJob.log"So why does it create a batch file to set the command prompt?
sorry forget this line i was trying something outhere's what i have done so far but i have problem working with parameters

echo off
echo h:\logthis.BAT
Rem Create the Batch Program containing the Prompt Command
Echo @Prompt $D $T > MakeProm.bat
Rem Execute the Prompt command and add the results to the log fil
command /c MakeProm.bat >> "h:\LogJob.log"
rem run the program to view parameters

if not "%1"=="" %1
echo %2
echo %3


pause

****************************************************************

How about....

echo|date /t > logfle
echo|time /t >> logfle (appends time to date info on the file)

You execute another batch file passing parameters with the CALL command:

Call Batch2.bat %1 %2

You can also make use of PROMPT and pipe that in for a parameter. See "Command line REFERENCE A-Z", and also "Batch Files" in Win Help.

Andy



Discussion

No Comment Found