Author Topic: Hiding desktop.ini  (Read 999 times)

jimg

  • Member
  • ***
  • Posts: 339
Hiding desktop.ini
« on: September 08, 2019, 07:58:14 AM »
I like to see all the files on my computer when I browse through folders, but since converting to windows 10, the setting to do so also shows the two desktop.ini files on my desktop.   This has made me even more crazier than usual, and I spent a lot of time trying to remedy the problem.

Finally, I stumbled upon a solution.  https://www.wisecleaner.com/wise-folder-hider-free.html

I can't figure out what's it doing, but it does it beautifully.   I don't use any of the password protections, etc., just to hide desktop.ini so it's overkill for me, but it works!

Biterider

  • Member
  • ***
  • Posts: 391
  • ObjAsm32 + ObjAsm64 = ObjAsm
    • ObjAsm
Re: Hiding desktop.ini
« Reply #1 on: September 08, 2019, 05:26:52 PM »
Hi
I'm wondering, how they do that  :rolleyes:

Biterider

Vortex

  • Member
  • *****
  • Posts: 2030
Re: Hiding desktop.ini
« Reply #2 on: September 08, 2019, 06:35:24 PM »
Quote
The Desktop displayed by Windows is a combination of your user's Desktop and the Public Desktop folder. The Public Desktop folder is used automatically by all the users on your computer. It is located in the folder "C:\Users\Public\Desktop" and it holds the items that are available on every user's standard Desktop.

Windows, Dekstop, Desktop.ini, files, what they are, what they do
You see two Desktop.ini files because your Desktop is a combination of two folders, each with its own Desktop.ini file: one for your user account and one for the Public Desktop.

https://www.digitalcitizen.life/why-are-there-two-desktopini-files-my-desktop-what-do-they-do
Quote
One of them is in the “All Users” profile (%PUBLIC%\Desktop). The other is in your profile (%USERPROFILE%\Desktop). They are both hidden system files. If you want them to disappear, you will have to set Windows Explorer to hide them. This is also the default setting.

https://www.howtogeek.com/198704/why-are-there-two-desktop.ini-files-on-windows-desktops/

hutch--

  • Administrator
  • Member
  • ******
  • Posts: 6749
  • Mnemonic Driven API Grinder
    • The MASM32 SDK
Re: Hiding desktop.ini
« Reply #3 on: September 08, 2019, 08:24:13 PM »
I am a barbarian, I just delete it.
hutch at movsd dot com
http://www.masm32.com    :biggrin:  :skrewy:

jimg

  • Member
  • ***
  • Posts: 339
Re: Hiding desktop.ini
« Reply #4 on: September 09, 2019, 12:25:42 AM »
Vortex-

Yes, exactly what I have found to this point.  But the only way to tell windows 10 to hide them is to hide all system/hidden files.  I want to see them when I browse, just not on my desktop :)

Caché GB

  • Member
  • **
  • Posts: 89
  • MASM IS HOT
Re: Hiding desktop.ini
« Reply #5 on: September 11, 2019, 03:43:52 PM »
Caché GB's 1 and 0-nly language:MASM

Biterider

  • Member
  • ***
  • Posts: 391
  • ObjAsm32 + ObjAsm64 = ObjAsm
    • ObjAsm
Re: Hiding desktop.ini
« Reply #6 on: September 11, 2019, 03:55:40 PM »
Hi Caché GB
Thanks for the link.  :thumbsup:

It seems that Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D} does the trick  :icon_idea:

Regards, Biterider



sinsi

  • Member
  • *****
  • Posts: 1185
Re: Hiding desktop.ini
« Reply #7 on: September 16, 2019, 01:58:01 AM »
Overkill for sure  :biggrin:

Why not use your DIP code to position the icon off-screen?
I can walk on water but stagger on beer bourbon.

hutch--

  • Administrator
  • Member
  • ******
  • Posts: 6749
  • Mnemonic Driven API Grinder
    • The MASM32 SDK
Re: Hiding desktop.ini
« Reply #8 on: September 16, 2019, 02:10:34 AM »
I still think that deleting it is simpler and faster.  :tongue:
hutch at movsd dot com
http://www.masm32.com    :biggrin:  :skrewy:

jimg

  • Member
  • ***
  • Posts: 339
Re: Hiding desktop.ini
« Reply #9 on: September 16, 2019, 02:40:22 AM »
Sinsi-
Yeah, I did that for years, but windows just keeps moving it back.

Also deleted it for a long time, but again, windows just keeps recreating it.

This may be a sledgehammer, but it works.

sinsi

  • Member
  • *****
  • Posts: 1185
Re: Hiding desktop.ini
« Reply #10 on: September 17, 2019, 11:03:40 AM »
Added a registry value, deleted the ini files, several reboots later the files aren't there (so far).

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer
DWORD UseDesktopIniCache=0

Several internet sites say this doesn't work in later win10 releases, so we shall see...
I can walk on water but stagger on beer bourbon.

jimg

  • Member
  • ***
  • Posts: 339
Re: Hiding desktop.ini
« Reply #11 on: September 17, 2019, 11:29:10 AM »
Now install a new program that puts an icon on the desktop.  If that doesn't do it, I'm sold.

hutch--

  • Administrator
  • Member
  • ******
  • Posts: 6749
  • Mnemonic Driven API Grinder
    • The MASM32 SDK
Re: Hiding desktop.ini
« Reply #12 on: September 17, 2019, 11:37:01 AM »
 :biggrin:

This DOES work.

C:\Users\YourUserName\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup>

Use a batch file to delete the desktop.ini file.

LATER You can scrap that idea, a batch file will not delete the desktop.ini file.
hutch at movsd dot com
http://www.masm32.com    :biggrin:  :skrewy:

sinsi

  • Member
  • *****
  • Posts: 1185
Re: Hiding desktop.ini
« Reply #13 on: September 17, 2019, 02:27:25 PM »
>Now install a new program that puts an icon on the desktop.  If that doesn't do it, I'm sold.
Installed VLC with icon, rebooted, still no desktop.ini

>LATER You can scrap that idea, a batch file will not delete the desktop.ini file.
attrib desktop.ini -h -s -r
del desktop.ini
I can walk on water but stagger on beer bourbon.

AW

  • Member
  • *****
  • Posts: 2431
  • Let's Make ASM Great Again!
Re: Hiding desktop.ini
« Reply #14 on: September 17, 2019, 06:23:48 PM »
We can do it with a Windows Service that monitors changes on the desktop folders. https://docs.microsoft.com/en-us/windows/win32/fileio/obtaining-directory-change-notifications
First, it runs through all files at start up to see if any desktop.ini is there and delete it, then seats waiting. If there is a change notification for a desktop.ini, delete it.

It would be an interesting exercise, particularly because I don't recall ever seeing a Windows Service done in ASM.