Refresh Windows Explorer lazarus / 34-Windows ---------------------------------------------------------------------- Newmann · 2013-07-09 03:52 Hi guys, Does anybody know a quick/easy way to refresh windows explorer? Just the general "RClick Desktop-> Refresh" kind of refresh is what I need to do... ---------------------------------------------------------------------- howardpc · 2013-07-09 06:37 F5 is the OS default shortcut in most Windows versions to refresh Explorer. Or are you asking about manipulating Explorer under the control of a Lazarus program? ---------------------------------------------------------------------- Newmann · 2013-07-11 03:39 Yes - programmatically. ---------------------------------------------------------------------- BigChimp · 2013-07-11 08:39 Perhaps this StackOverflow question+answers can help if there is no built-in way in the LCL (and I assume there isn't): http://stackoverflow.com/questions/4940603/how-to-refresh-windows- explorer ---------------------------------------------------------------------- Newmann · 2013-07-11 13:24 I know about this post at StackOverflow - one of the many ones I read before posting this thread. Killing Explorer and relaunching it is very easy yes - but I need to refresh it without killing it...thats my problem. The reason for this is that when you refresh the desktop, Windows records the position of the icons - and that is what I'm actually after... ---------------------------------------------------------------------- BigChimp · 2013-07-11 13:40 Don't really see where killing Explorer comes up in that page I linked to but haven't looked all that closely. So you might try sending it some messages as indicated in that page... perharps there's some icon refresh thing mentioned somewhere in MSDN. Anyway, it doesn't seem to be FPC specific so you might have more luck on MS C++ forums/sites... ---------------------------------------------------------------------- Newmann · 2013-07-30 18:31 Managed to figure this one out when I was researching a way to get past Group Policy in windows! All you need to do is a shell execute: Code: [Select]RUNDLL32.EXE user32.dll,UpdatePerUserSystemParameters This causes explorer to refresh and apply any necessary changes. Not sure if its the best option though, but it works well enough...