Posted by 20080217 on February 17, 2008 at 06:35:21:
In Reply to: dos Batch File and Flash Drives posted by Frank Hopkins on February 15, 2008 at 22:58:13:
: I have been using a DOS database program called
: Dataease since 1986. I have recently run into a
: problem running the program from a flash drive
: when I take the flash drive from one computer to
: another. The batch file is as follows:
:
: cd\temp
: del *.tmp
: cd\
: call F:\Depro\de16m.exe Orders SalesPad Frank FH
:
: Each computer seems to recognize the flash
: drive as a different letter or drive location.
: Could you please tell me if it is possible to
: insert some type of input commandin the line
: where I call the program from a specific drive?
:
: In the code herein I am running on drive F
: however at my office I would like to run the
: program from drive M. So what I am asking is if
: I can call the program from any drive
: input letter?
: Thanks for any consideration you might give
: my question.
##
Change the "F:" in your batch file to "%1" (without the quotes).
Then when you launch the batch file, specify the drive letter on the command line. For example, if your batch file was named "foobar.bat" and the drive letter of your flash drive is "F:" you would type:
foobar f:
If the drive letter of your flash drive was "M:", then the command would be:
foobar m: