markmorgan47 Posted April 15, 2008 Posted April 15, 2008 I am creating a folder called "XYZ" on the root of C:\ for several programs and then copying these programs to those folders. I then want to have a text file with instruction open up to let the user know where the programs were copied to and what to do next. Here is my code I have which works except for opening the text file.MAKEDIR "%SystemDrive%\Mitech Tools\ADO Query"FILECOPY "%wpipath\Install\Mitech Tools\ADO Query\ADOQuery.exe" "c:\Mitech Tools"FILECOPY "%wpipath\Install\Mitech Tools\Instructions.txt" "c:\Mitech Tools""%SystemDrive%\Windows\NOTEPAD.EXE" "c:\Mitech tools\Instuctions.txt"The last line of code always comes back with an error of "Cannot find "C:\Mitech Tools\Instructions.txt" do you want to create a new one. I checked and the text file was copied to the correct locations. So I have also tried the following code for the last line."%root%\Windows\NOTEPAD.EXE" "c:\Mitech tools\Instuctions.txt"and"c:\Windows\NOTEPAD.EXE" "c:\Mitech tools\Instuctions.txt"They all give me the same code. Is there an easier way or am I doing something wrong in the code. Thanks in advance.Mark
Kelsenellenelvian Posted April 15, 2008 Posted April 15, 2008 Simply call the text file and it will open in the defualt veiwer."c:\Mitech tools\Instuctions.txt"
Scr1ptW1zard Posted April 16, 2008 Posted April 16, 2008 May be a typo...FILECOPY "%wpipath\Install\Mitech Tools\Instructions.txt" "c:\Mitech Tools""%SystemDrive%\Windows\NOTEPAD.EXE" "c:\Mitech tools\Instuctions.txt"Shouldn't that be:"%SystemDrive%\Windows\NOTEPAD.EXE" "c:\Mitech tools\Instructions.txt"
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now