Microsoft KB Archive/810146

= Scripts that check the %errorlevel% system variable may return inconsistent values when run on a Windows 2000-based computer with Terminal Services components installed =

Article ID: 810146

Article Last Modified on 10/26/2006

-

APPLIES TO


 * Microsoft Windows 2000 Advanced Server
 * Microsoft Windows 2000 Professional Edition
 * Microsoft Windows 2000 Server

-





SYMPTOMS
When you use the End Task function in Task Manager to end a script that checks the %errorlevel% system variable on your Windows 2000-based computer, the %errorlevel% system variable may incorrectly return a 0 instead of a 1.



CAUSE
This problem occurs when your Windows 2000-based computer has the Terminal Services component installed.

The %errorlevel% system variable returns the following values when the following conditions are true:
 * On a Windows 2000-based computer that does not have the Terminal Server components installed, the %errorlevel% variable returns echo 1.
 * On a Windows 2000-based computer with the Terminal Services components installed, the %errorlevel% system variable returns echo 0.



Hotfix information
A supported hotfix is now available from Microsoft, but it is only intended to correct the problem that is described in this article. Only apply it to systems that are experiencing this specific problem. This hotfix may receive additional testing. Therefore, if you are not severely affected by this problem, we recommend that you wait for the next Windows 2000 service pack that contains this hotfix.

To resolve this problem immediately, contact Microsoft Product Support Services to obtain the hotfix. For a complete list of Microsoft Product Support Services telephone numbers and information about support costs, visit the following Microsoft Web site:

http://support.microsoft.com/contactus/?ws=support

Note In special cases, charges that are ordinarily incurred for support calls may be canceled if a Microsoft Support Professional determines that a specific update will resolve your problem. The usual support costs will apply to additional support questions and issues that do not qualify for the specific update in question.

Prerequisites
No prerequisites are required.

Restart requirement
You do not have to restart your computer after you apply this hotfix.

Hotfix replacement information
This hotfix does not replace any other hotfixes.

File information
The English version of this has the file attributes (or later) that are listed in the following table. The dates and times for these files are listed in coordinated universal time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time tool in Control Panel.

  Date         Time   Version            Size    File name --  20-Nov-2002  20:58  5.0.2195.6134      87,312  Taskmgr.exe



STATUS
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the &quot;Applies to&quot; section of this article.



MORE INFORMATION
For additional information about how to obtain a hotfix for Windows 2000 Datacenter Server, click the following article number to view the article in the Microsoft Knowledge Base:

265173 The Datacenter Program and Windows 2000 Datacenter Server product

For additional information, click the following article number to view the article in the Microsoft Knowledge Base:

824684 Description of the standard terminology that is used to describe Microsoft software updates

Keywords: kbhotfixserver kbqfe kbfix kbbug kbprb kbwin2000presp4fix KB810146

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.