Author Topic: Bug: Desktop Icon placement not saved across sessions + Workaround  (Read 272 times)

0 Members and 1 Guest are viewing this topic.

Offline flatline23

  • Newbie
  • *
  • Posts: 4
Bug:  Desktop icon placement/positions under Windows 10 don't get saved across sessions since latest Avast program update when using a non-preset icon size.

Reproduce:

First, turn off auto arrange.  Right click the desktop -> View -> Uncheck Auto-Arrange

Next, select an icon size preset.  Right click -> View -> Small Icons

Now, increase it by one step.  Hold down Control and scroll up with the mouse wheel one click.  The desktop icons should change size, and now you are in a non-preset mode.

Reboot.  Now it's the default in Windows, and Avast has now (for some reason) locked the iconcache_custom_stream.db file at %APPDATA%\Local\Microsoft\Windows\Explorer.   This is the file that contains the info for icon placement at a non-preset size, and with it locked, any changes you make will not be saved.

You can see the behaviour by moving an icon to somewhere else.  Then change icon size via control-mousewheel up one, then back down one.  The icon position will go back to where it was.  This is not expected behaviour.  Weirdly, doing this on one of the preset icon sizes doesn't seem to have this issue.  Test it by selecting one of the presets, move an icon, then ctrl-mousewheel up then down again, and you'll see the icon position gets saved and restored no problem.

Further... trying to clear out the icon cache fails, even when explorer isn't running.  Open a command prompt and navigate to that folder.  Kill Explorer.exe in Task Manager.  Now try to delete the iconcache*.* files.  It  will fail on two of them because Avast has locked them.

Workaround:

Disable all Avast shields.  Place icons where you want them.  Make sure they are saved by refreshing the desktop and changing icon sizes a few times.  Then re-enable shields.

Better Workaround:

Put %APPDATA%\Local\Microsoft\Windows\Explorer in your Avast exceptions.  (Replace %APPDATA% with the actual path, i.e. C:\Users\Username\AppData\Local\Microsoft\Windows\Explorer).  The files no longer get locked, and icon placement is saved and restored across sessions at all resolutions and sizes.

Truly annoying bug and much hair pulling occurred tracking it down to Avast.  I thought it might have been the Anti-Ransomware module at first, but uninstalling that had no effect.  I'm guessing it's exempting the standard sizes but for some reason not the custom size.  The manual exemption seems to work though.

Just posting all this here in case someone else has encountered this bug.  It may even apply to other antivirus products that get over-zealous about protecting certain files.