Computing.Net > Forums > Disk Operating System > basic batch file help needed

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

basic batch file help needed

Reply to Message Icon

Name: Nicholas Bostaph
Date: July 2, 1999 at 07:23:18 Pacific
Comment:

I attempting to write a batch file and am having trouble when running it. There is a line in the file:

'type lastdir.txt > pos'

I am using this line to put the contents of the text file which is simply the number 5 into the variable 'pos'. However, whenever I run the file with echo on it shows up on screen as:

'type lastdir.txt 1>pos'

It adds a 1 before the arrow and deletes the space after. Obviously this causes it not to work. Does anyone know why it does this or how to fix it. I'd appreciate any input. I'd prefer an e-mail to a reply. Thanks for your time.



Sponsored Link
Ads by Google

Response Number 1
Name: Enduser
Date: July 5, 1999 at 19:47:07 Pacific
Reply:

Without viewing the batch file I can't tell why it would do this. I can tell you a few things. You don't need a spaces before or after the redirection key (the arrow)except for the one after the type command. I could give it a lookie if you want to email the file.

Enduser


0

Response Number 2
Name: khalid
Date: July 2, 2000 at 23:01:16 Pacific
Reply:

iam trying to make a batch file so that it copies some dll files from the cdrom from to the system directory.
since the cdrom drive letter may vary in different systems iam trying to accept an input from the user for entering the cd rom drive letter and then using that input in the copy command.

how should i go about doing this or is there any other workaround?

please respond.(iam in very urgent need of your help)

awaiting your reply.


0

Sponsored Link
Ads by Google
Reply to Message Icon

Related Posts

See More







Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Disk Operating System Forum Home


Sponsored links

Ads by Google


Results for: basic batch file help needed

Batch file help needed www.computing.net/answers/dos/batch-file-help-needed/748.html

IF command-Batch file help needed! www.computing.net/answers/dos/if-commandbatch-file-help-needed/13047.html

Batch File Help www.computing.net/answers/dos/batch-file-help/10785.html