Computing.Net > Forums > Disk Operating System > Errorlevel

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.

Errorlevel

Reply to Message Icon

Name: Samuel Lourenco
Date: September 26, 2002 at 06:37:48 Pacific
OS: Windows 98
CPU/Ram: 200 MMX 40MB
Comment:

I want to know if copy command can generate errorlevel.

I made the following in Batch:
copy Morfit.dll C:\WINDOWS\System
if errorlevel 1 echo Copy error: 'System' directory in may be locked.

I write protected system folder and then ran the batch. But message didn't apeared.




Sponsored Link
Ads by Google

Response Number 1
Name: Guti
Date: September 26, 2002 at 07:22:55 Pacific
Reply:

Try a echo %errorlevel% to see what code is returning.


0

Response Number 2
Name: Guti
Date: September 26, 2002 at 07:24:41 Pacific
Reply:

As far as I have tested it seems that the internal commands does not return any code.
Maybe you can use xcopy instead for your purposes.


0

Response Number 3
Name: Secret_Doom
Date: September 26, 2002 at 10:52:17 Pacific
Reply:

As far as I could see, the copy command doesn't seem to change the errorlevel. Nevertheless, as Guti said, XCOPY returns various errorlevels.

Guti wrote:
> Try a echo %errorlevel% to see
> what code is returning

Samuel is using Win98. That tip you gave is only valid for NT systems.

-- Leonardo Pignataro - Secret_Doom --

secret_doom@hotmail.com
www.batch.hpg.com.br


0

Sponsored Link
Ads by Google
Reply to Message Icon

Related Posts

See More


Memory-Problem with DOS Dos Window



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: Errorlevel

xcopy errorlevels??? www.computing.net/answers/dos/xcopy-errorlevels/7510.html

Multiple Errorlevels in IF-command! www.computing.net/answers/dos/multiple-errorlevels-in-ifcommand/10704.html

ftp errorlevels ( exit values ) www.computing.net/answers/dos/ftp-errorlevels-exit-values-/1167.html