General discussion

Locked

CDROM Drive letter from Batchfile

By degthat ·
I am try to launch a batch file from an autoplay CD. The batch file resides on the root of the cd. It creates the diretory I asked for but it says it can't find the files I want to copy. Here is what I have.....


ECHO ON

PATH=%CDROM%\:
pause

xcopy \files\*.* C:\EA-6B\

ATTRIB -R c:\EA-6B\*.*

What am I doing wrong ? Or better yet how do I get this to work ?

This conversation is currently closed to new comments.

3 total posts (Page 1 of 1)  
| Thread display: Collapse - | Expand +

All Comments

Collapse -

CDROM Drive letter from Batchfile

by bigsparky In reply to CDROM Drive letter from B ...

It looks like your Set Path statement is wiping out the old path, and unless xcopy and attrib are on the cd then it won't be able to find them. try setting the path string like this:
SET PATH=%PATH%;%CDROM%\:
I'm not sure the semi-colon after %path% is required but it shouldn't hurt.
Assumes of course that CDROM is defined

Collapse -

CDROM Drive letter from Batchfile

by degthat In reply to CDROM Drive letter from B ...

Poster rated this answer

Collapse -

CDROM Drive letter from Batchfile

by degthat In reply to CDROM Drive letter from B ...

This question was closed by the author

Back to Web Development Forum
3 total posts (Page 1 of 1)  

Related Discussions

Related Forums