Sounds like Your win 8 os is handling the path differently ?
Can you read the path into a string var and see if it matches
sometimes I hear windows do funny things to paths, like adding
empty char to the end ??
path := ExtractFilePath(Application.ExeName);
// This line was changed to the line below showmessage(path);
if there is a invisible char showmessage will not rereal it.
so we should instead do something line
memo1.text := path;
and compare length(path); with actual win 8 path
C:\Windows\System32\ie4uinit.exe this line = 32 chars
so if path is more then 32 char we have found win 8 added char
but i wander if you could instead use Tprocess with parameters
launching the cmd.exe and passing 'ie4uinit.exe', '-ClearIconCache' as
your pameters this works on linux using sh should be same concept
as cmd.exe on windows but i don't use windows so just a thought ?
Read my post on Tprocess execute method
rather then use sh with -c
try to cmd.exe or whatever the extention is perhaps not even need to know extention.
After some reading on cmd i found that you can use /c in the place of -c
in my code. You should be good to go just change needed parmeter and the executable
to cmd
http://wiki.lazarus.freepascal.org/Executing_External_Programs#A_Simple_ExampleIf using Tprocess executable with parmeters don't work for you try
the depreciated method using commandline instead
Hope this helps