Options

Difference between %windir% and %systemroot%

Can someone explain the difference between %windir% and
%systemroot%? They both point to c:\windows\.

Comments

  • Options
    3000GT3000GT Member Posts: 212
    i thought %windir% was just the default c:\windows and %systemroot% was just the c:\ drive?
  • Options
    w^rl0rdw^rl0rd Member Posts: 329
    Maybe my variable was changed.
    I'm on my work machine and it goes to c:\windows if
    you type %systemroot% from Run.
  • Options
    jescabjescab Inactive Imported Users Posts: 1,321
    they both go to my C:\WINDOWS directory.
    GO STEELERS GO - STEELERS RULE
  • Options
    w^rl0rdw^rl0rd Member Posts: 329
    jescab wrote:
    they both go to my C:\WINDOWS directory.

    Any idea why both variables point to the same location?
  • Options
    jescabjescab Inactive Imported Users Posts: 1,321
    I don't have a clue. I hope somebody can help us out and tell us why.
    GO STEELERS GO - STEELERS RULE
  • Options
    WebmasterWebmaster Admin Posts: 10,292 Admin
    If I remember correctly, the systemroot variable is for NT systems and above and windir for older windows versions (i.e. 95/9icon_cool.gif. I think the windir variable is still present for compatibility reasons. I.e. some applications might still use it.
  • Options
    w^rl0rdw^rl0rd Member Posts: 329
    Webmaster wrote:
    If I remember correctly, the systemroot variable is for NT systems and above and windir for older windows versions (i.e. 95/9icon_cool.gif. I think the windir variable is still present for compatibility reasons. I.e. some applications might still use it.

    That sounds about right. I bet if anyone has a 9x system and runs the SET command from MS-DOS, you will see the WinDir variable and not SystemRoot.

    Thanks Everyone, Authenticated Users, Domain Admins, and Guest. :)
  • Options
    JcwwumingJcwwuming Registered Users Posts: 1 ■□□□□□□□□□
    Webmaster wrote: »
    If I remember correctly, the systemroot variable is for NT systems and above and windir for older windows versions (i.e. 95/9icon_cool.gif. I think the windir variable is still present for compatibility reasons. I.e. some applications might still use it.



    Yes %windir% is for win 9x, %systemroot% is fot win nt & above, but %windir% remain to use..
Sign In or Register to comment.