Hi Jared and anyone else who might be watching this thread,
After some quick research, with help from your pointer, I have determined
that it's not ShowSuperHidden that controls the visibility of hidden or
system files. The field/item that needs to be read is "Hidden".
BTW: Code to access and read the value in C#.
//Determines if the current user has set Show Hidden/System files on or off.
private bool HiddenFilesAreInvisible()
{
bool blnHideFiles = true;
RegistryKey rkyCurrentUser = Registry.CurrentUser;
rkyCurrentUser =
rkyCurrentUser.OpenSubKey(@"Software\Microsoft\Windows\CurrentVersion\Explor
er\Advanced",false); //Open Read Only
string strShowHidden = rkyCurrentUser.GetValue("Hidden").ToString();
//According to my research when the "Hidden" field is set to 1 the files
are visible, when its' value is 2 they are invisible.
if(strShowHidden=="1")
blnHideFiles = false;
rkyCurrentUser.Close();
return blnHideFiles;
}
Thanks
Regards
Greg
Jared Parsons said:
These values are actually stored in the registry. Here is a link explaining
the keys and values.
http://www.winguides.com/registry/display.php/961/
--
Jared Parsons [MSFT]
(e-mail address removed)
This posting is provided "AS IS" with no warranties, and confers no rights.
OR if you wish to include a script sample in your post please add "Use of
included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm"
Greg Bell said:
Hi,
Can someone tell me where to look to enable me to read "Folder Options" user
settings for hidden/system files from within C#/VB.Net/Any other .NET
language. I'm pretty sure it must be part of the framework, but I'm buggered
if I can figure out which part. I've tried googling for it, but to no avail.
Any ideas?
Thanks
Greg