I have an application that loads .exe into a temporary folder and runs it with a class System.Diagnostics.Process. So far, I have run two different applications with it. One of them is a console application, the other is a full-window application. A Windows application has its own icon in the taskbar / header, but the console application has only a common application icon. If I go to the temp folder, the console application has its own icon; and starting it manually (double-clicking in Explorer) also gives it the correct icon.
What could be the reason for this?
Additional Information: The class ProcessStartInfodoes not offer any flags regarding the icon. I am starting the process with UseShellExecute=trueand ErrorDialog=true. In addition, the Windows application runs as much as possible, but the console application is minimized (as indicated by the WindowStylemember ProcessStartInfo). Finally, the console application icon contains only the 32x32x4bpp icon, and the Windows application has a large selection of different formats.
Added: I gave the downloaded application the correct icon. Still no.: (
Added 2: Oh, well, Windows 7 x64.
Update: Just tried a few more experiments. I created a new C ++ application (unmanaged, not .NET), simply by pressing any key to continue, and gave it an icon. The icon is usually displayed in Explorer, and when I launch it from Explorer, the icon is in the title bar of the window.
However, when I launch the application from Visual studio (via F5 or Ctrl-F5); or when I run the application through another .NET application and Process.Start()- the icon does not appear. Why?
Vilx- source
share