Jump to content

Recommended Posts

Posted

I have files that I would like to move from my unattended disc to a different drive then the C: where windows is installed.

I have a C:, D:, & E: I know how that the $OEM$ gets moved onto the C: during install. And then is there a way I can make a batch file that moves files from the c:/installs folder to a certain folder that I have on the D:?

So I want C:/installs/FILENAME.EXT to be moved to the D:/programs/ folder. And I want it to run within my batch file when its install all my programs.

-J


Posted

You mean something like this:

if not exist D:\nul GOTO :ERROR1
if not exist D:\programs MD D:\programs
if not exist D:\programs\folder MD D:\programs\folder
if exist C:\installs\FILENAME.EXT COPY /V C:\installs\FILENAME.EXT D:\programs\folder
if exist C:\installs\FILENAME.EXT DEL /F C:\installs\FILENAME.EXT
GOTO :NEXTACTION

:ERROR1
ECHO DRIVE D: does not exist! .... aborting....
GOTO :END

:NEXTACTION
::WHATEVER ELSE YOU WANT TO DO

:END

jaclaz

Posted

Well, its a bit simpler than that....

Just make the correct drive-letter as a folder within the OEM folder.

For example, make the folder "$OEM$\D".

And put all files and folders that you want to go from CD to D drive over there.

So, if you want "MySettings" folder to be present on D: drive (like D:\MySettings), then put that folder into the "D" folder in OEM folder. So, you can put it as "$OEM$\D\MySettings". It will be copied.

Then, you can run whatever you want from your batch-files to deal with the copied file.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...