Showing results for 
Show  only  | Search instead for 
Did you mean: 
Level 5

Problem restarting explorer on Windows 64bit

I need to kill and start the explorer so the iconcache.db can be rebuild. This works all correctly on a 32 bit OS. But not on windows 2008 R2 or windows 7 64 bit. The result is explorer starts up but not as shell(taskbar and desktop are missing). Does anybody know why this happens?
Code used:

if IconCacheNeedsRebuilding() then
lIconCacheFileName = FOLDER_LOCAL_APPDATA^"\IconCache.db";
lTaskKillResult = LaunchAppAndWait(WINSYSDIR^"taskkill.exe", " /IM explorer.exe /F", LAAW_OPTION_WAIT);
lExplorerProcessExists = IsProcessRunning("explorer");
lIterations = lIterations + 1;
until !lExplorerProcessExists || (lIterations < WAIT_FOR_EXPLORE_KILLED_MAX_ITERATIONS);
LaunchApp(WINSYSDIR^"explorer.exe", "");

btw lTaskKillResult gives a result of 0
Labels (1)
0 Kudos
(3) Replies
Level 9

InstallShield 32Bit Setup does call 32-Bit apps. They can not see the 64-Bit part of system.
You have to write your own 64-Bit app to kill proccess. You starts it using LaunchAppAndWait.
0 Kudos
Level 5

taskkill in this code kills the explorer process. The problem is that at that point there is no shell and starting up explorer after that does not start the explorer in shell mode. I also tried using a delay of 60 seconds in between killing and restarting the explorer.
0 Kudos
Level 2

may have solved your problem with the restart explorer process, after deleting iconcachedb file?
0 Kudos