Re: Whats the %=C:% environment variable used for ?

"R.Wieser" <[email protected]> Sat, 7 Feb 2026 11:13:13 +0100
Newsgroups alt.comp.os.windows-xp,alt.windows7.general,alt.comp.os.windows-10
Organization A noiseless patient Spider
Message-ID <[email protected]>
Frank,

>> >  Current working directory, to be precise.
>>
>> Nope, thats something else.
>
>  No, it is,

Yes, it is.  Prove me wrong, why don't you.

Thats the whole problem with people like you.  You guys claim wrongdoing, 
but for "some reason" (yeah, right) "forget" to provide substanciation for 
such a claim.

.. I wonder why ... <whistle>

> but - as usual - you snipped the/your context.

And as always you complain about me/others do not quote to your liking but 
*as always* "forget" to mention how they *should* have done it.

Ofcourse, if you /would/ do that than there is a big chance that me/those 
others would point out that most of what you want to see quoted has zero to 
do with the provided reply.

You think otherwise ?  Than put your money where your mouth is and prove it.

Also, in the past you've shown yourself to be quite hypocritical about such 
quoting, snipping stuff that was actually part of what re reply was about.

Bottom line,
your "you're (quoteing) wrong!" <full stop> claims have long ago ceased to 
impress me.

>> > "The %=C:% environment variable in Windows is a hidden, special
>> > system-wide variable that stores the current working directory
>> > for the C: drive.
>
>  See? "current working directory", like I said.

What I see is that you "forgot" to read the whole line, especially the part 
after "current working directory".  Whats that about again about others 
snipping important information ?   You're the pot who claims that the kettle 
is black.

FYI: Windows processes have a "current working directory" that has *nothing* 
to do with the ones for each drive.

Worse : programs do not even have a possibility to do a "cd".  Thats all the 
command processors doing.

>> Its certainly not system-wide.
>
> It probably was in the "legacy mechanism". Another part you
> snipped.
>
> See a pattern there!? :-(

Yeah, I do.  You have very little actual knowledge about how Windows works 
and even when someone hits you with a clue bat you will refuse to check it 
out for yourself.

>> > Here are the key details about %=C:%:
>> [snip]
>>
>> That explains nothing about its usage.
>
>  It's usage is rather obvious from the snipped (Sigh!) example.

:-)  Kiddo, I said *USAGE*, not how the command-processor changes it when 
you do something like a CD. Learn to read.  *Deep sigh*

> The others had no problems understanding it's usage, See for
> example, but not only, Kenny's response.

Most all of the others skirted the question. Just like you.  Only one person 
provided something thats plausible, and it wasn't Kenny.

>> The question still stands : What is the "=C:" environment variable used
>> for ?
>
>  Sigh!
>
>  To know the current working directory on the C: drive, when the
> active working directory is on another drive.

Idiot.  You must have never heard of relative paths.

And no, a programmer being of sound mind would *not* use that environment 
variable for it.  There are better ways to get a drives "current working 
directory".

>  As it's an environment variable, it can be used in other commands,
> etc..

And there we are, arriving at the question (in the caption and the first 
post) : Whats the %=C:% environment variable used for ?

In all my years I've never seen it used (in batch files or otherwise). 
Probably because command processors also recognise and can work with 
relative paths.

Regards,
Rudy Wieser