There's no such thing as a stupid question, but they're the easiest to answer.
JoinTour
Login
 
Tag Cloud
access audio avg avg 8 bios blue screen boot bsod computer connection cpu crash css dell desktop dma driver drivers dvd email error excel explorer firefox firefox 3 freeze gimp graphics hard drive hardware hijackthis hjt install internet internet explorer itunes keyboard laptop macro malware monitor motherboard network networking outlook outlook 2003 outlook 2007 outlook express pio problem problems router seo server slow sound sp3 spyware trojan usb video virtumonde virus vista vundo windows windows vista windows xp winxp wireless
DOS/PDA/Other
Search
Search in:
 
Advanced Search
Tech Support Guy Forums > Operating Systems > DOS/PDA/Other >
Batch file to enable diable hidden files


HELLO AND WELCOME! Before you can post your question, you'll have to register -- it's completely free! Click here to join today! We highly recommend that you print a copy of our Guide for New Members. Enjoy!

 
Thread Tools
G-Stress's Avatar
Senior Member with 113 posts.
 
Join Date: Feb 2008
07-Jul-2008, 08:02 PM #1
Batch file to enable diable hidden files
Hey guys, I'm looking for a way to create a simple batch file to enable disable the view of hidden files. One that would work with XP/Vista. I can think of a way to create a batch to set all/certain file types to hidden/unhidden, but can't think of a way to just enable/disable currently hidden files. Any advice is greatly appreciated.
Squashman's Avatar
Distinguished Member with 12,590 posts.
 
Join Date: Apr 2003
Location: 1265 Lombardi Ave
07-Jul-2008, 08:25 PM #2
Not sure if this value is the same in the registry for Vista. Here is the registry value in XP.
http://www.pctools.com/guides/registry/detail/1007/
ghostdog74's Avatar
Member with 90 posts.
 
Join Date: Dec 2005
09-Jul-2008, 07:29 AM #3
attrib ??
G-Stress's Avatar
Senior Member with 113 posts.
 
Join Date: Feb 2008
09-Jul-2008, 05:50 PM #4
Quote:
Originally Posted by Squashman View Post
Not sure if this value is the same in the registry for Vista. Here is the registry value in XP.
http://www.pctools.com/guides/registry/detail/1007/
It's been a minute since I've created a .reg file would I just save

[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\
Advanced]

as a reg file? Where I'm lost is where would I set the value at in a .reg file or .bat if possible?

@ ghostdog74

If I'm understanding properly your saying create a .bat to apply attrib +h ? Which that is what I had in mind but then I would have to set the specific destinations and files.

I'm just wanting to basically do the Folder Options --> Show hidden files, but in a .bat file, .reg file will work also.
Squashman's Avatar
Distinguished Member with 12,590 posts.
 
Join Date: Apr 2003
Location: 1265 Lombardi Ave
09-Jul-2008, 09:02 PM #5
You can get a Vbscript from here to toggle the settings.
http://www.edbott.com/weblog/?p=692

Or you can use this reg file. Copy and paste it into a text file but rename it with a .reg extension.
Code:
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced]
"Hidden"=dword:00000001
"HideFileExt"=dword:00000000
"ShowSuperHidden"=dword:00000001
If you want to call the registry file from a batch file you can do this.
showfiles.bat
Code:
regedit.exe /S showfiles.reg
__________________
I hate asking the same question twice!
How to ask questions the smart way!
Microsoft MVP - Windows Shell/User

Last edited by Squashman : 09-Jul-2008 09:18 PM.
G-Stress's Avatar
Senior Member with 113 posts.
 
Join Date: Feb 2008
09-Jul-2008, 11:12 PM #6
Quote:
Originally Posted by Squashman View Post
You can get a Vbscript from here to toggle the settings.
http://www.edbott.com/weblog/?p=692

Or you can use this reg file. Copy and paste it into a text file but rename it with a .reg extension.
Code:
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced]
"Hidden"=dword:00000001
"HideFileExt"=dword:00000000
"ShowSuperHidden"=dword:00000001
If you want to call the registry file from a batch file you can do this.
showfiles.bat
Code:
regedit.exe /S showfiles.reg


Nice... thanks man. This is the part I was unsure about as far as creating a .reg file to import.

Code:
"Hidden"=dword:00000001
"HideFileExt"=dword:00000000
"ShowSuperHidden"=dword:00000001
I couldn't remember how to set the values. This will definitely come in handy
Squashman's Avatar
Distinguished Member with 12,590 posts.
 
Join Date: Apr 2003
Location: 1265 Lombardi Ave
10-Jul-2008, 01:36 AM #7
Its just a matter of finding the correct registry key and then exporting it to a reg file. That is all I did.
G-Stress's Avatar
Senior Member with 113 posts.
 
Join Date: Feb 2008
10-Jul-2008, 12:22 PM #8
Ahhh... even better I didn't even think of it that way, I was only thinking of creating it manually
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are Off
Refbacks are Off

You Are Using:
Server ID
Advertisements do not imply our endorsement of that product or service.
All times are GMT -4. The time now is 03:05 PM.
Copyright © 1996 - 2008 TechGuy, Inc. All rights reserved.
Powered by vBulletin, Copyright © 2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0
Powered by Cermak Technologies, Inc.