Avatar of tdhumal
tdhumal

asked on 

Problem running batch script in command prompt

Hi Everyone,

I am running similar batch script on 2 different PC's. It works on one and does not work on other. Any idea why command prompt behave different?

Thanks,
Microsoft DOS

Avatar of undefined
Last Comment
tdhumal
Avatar of nettek0300
nettek0300

Can you please post the two scripts you running so that we can help you?
Avatar of tdhumal
tdhumal

ASKER

I will post them in few minutes
Avatar of Steve Knight
Steve Knight
Flag of United Kingdom of Great Britain and Northern Ireland image

Two suggestions - the scripts, and more points :-)
Avatar of tdhumal
tdhumal

ASKER

The scripts are same and the script works good in one PC and does not on other.
Unfortunately I cannot post the script. I even compared the script on both PC's. They are identical, but it does not work on on PC.

Is there any setting issues with command prompt??
Just wanted to get some ideas
Avatar of Steve Knight
Steve Knight
Flag of United Kingdom of Great Britain and Northern Ireland image

The idea with seeing the script is knowing what to aim for.... are the PC's the same OS, do they have the same PATH variable, is the script referring to any other files, exe's.  Do the users have the same NTFS or share rights, are the TEMP variables going to the same place.  Do they have the same network drives mapped?   Are CD / hard / flash drives given the same letters.... All or none of which may be relevant depending upon what the script is doing you see.
Avatar of tdhumal
tdhumal

ASKER

Thanks for your reply. I can check the OS and PATH values of the PC where the script does not work.
That is the only things which can be different.

I can post my findings tomorrow after 11:00am eastern time
You need to post the script.  Commands have different switches that are valid under different operating systems and sometimes even different behaviors under different operating systems.

We need to see what commands you are running, how you are parsing their output, what switches you are using, and know which operating systems you are running on in order to help you.

ALSO you are being very stingy with the points you have no limit of points you should increase the point value of this question to 500.
ASKER CERTIFIED SOLUTION
Avatar of Bill Prew
Bill Prew

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
Avatar of hari_b85
hari_b85
Flag of India image

Hi,

If you are not able to post the script, atleast let us know what result are you in search of..
This can help us in helping you.
Avatar of BillDL
BillDL
Flag of United Kingdom of Great Britain and Northern Ireland image

User generated image
Avatar of Steve Knight
Steve Knight
Flag of United Kingdom of Great Britain and Northern Ireland image

:-)
Avatar of BillDL
BillDL
Flag of United Kingdom of Great Britain and Northern Ireland image

Hi tdhumal

f your batch files contain some confidential information, would it be possible to maybe replace the confidential parts of the batch files with some non-confidential words or names and attach them as *.txt files.

It would be very, very useful for us to see the scripts rather than just making guesses about what could be wrong.

Bill
Avatar of Bill Prew
Bill Prew

@BillDL

:-)

~bp
Avatar of tdhumal
tdhumal

ASKER

echo off helped me get my problem fixed
Avatar of Bill Prew
Bill Prew

Great, glad that helped you get it sorted out.

~bp
Avatar of tdhumal
tdhumal

ASKER

Thanks to all the other responders. I really appreciate it
Microsoft DOS
Microsoft DOS

Microsoft Disk Operating System (MS-DOS) was an operating system for x86-based personal computers, and traces of it are still found in the Windows operating system. DOS is still used in some embedded systems and for certain legacy 16-bit networks.

14K
Questions
--
Followers
--
Top Experts
Get a personalized solution from industry experts
Ask the experts
Read over 600 more reviews

TRUSTED BY

IBM logoIntel logoMicrosoft logoUbisoft logoSAP logo
Qualcomm logoCitrix Systems logoWorkday logoErnst & Young logo
High performer badgeUsers love us badge
LinkedIn logoFacebook logoX logoInstagram logoTikTok logoYouTube logo