Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Reopen - Add My Documents desktop icon

Status
Not open for further replies.

Coldaddy

MIS
Jul 16, 2008
1
US
There was a great post by this name which markdmac answered...I had a question about the script provided, which was to add the "My Documents" icon onto the desktop. The question is, should the icon just appear (insert pop'ing sound here) when the script is run or should it show up after a logoff/logon? I ask because the script does not seem to work for me (on a Windows XP PC).

Script below:

[script]
'==========================================================================
'
' NAME: ShowMyDocumentsFolder.vbs
'
' AUTHOR: Mark D. MacLachlan , The Spider's Parlor
' URL: ' DATE : 8/11/2004
'
' COMMENT: <comment>
'
'==========================================================================
On Error Resume Next

Dim path

Set WSHShell = Wscript.CreateObject("WScript.Shell")

'set the key path here. IF you don't end with a '\' then WSH assumes you are pathing to a value.
path = "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\CLSID\{450D8FBA-AD25-11D0-98A8-0800361B1103}\ShellFolder\"

'Display the My Documents Folder
WSHShell.RegWrite path & "Attributes","4194676","REG_DWORD"

'Hide the My Documents Folder
'WSHShell.RegWrite path & "Attributes","5343252","REG_DWORD"



[/script]
I hope you find this post helpful. Please let me know if it was.

Regards,

Mark
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top