WPF Application dosen't start

2019-07-25 14:55发布

问题:

I have problem with starting WPF app based on MahApps style on others computers than my. I'm installing my app via Inno Setup. When I run .exe on my computer/computer with visual studio 2015 or sometimes on others computer, the application starts correctly. But when I install application on virtual machine which have just vs2008 + .Net or some others computers the application doesn't start. I can find the .exe in Task Menager, but no window is shown.

The best is that I install two WPF applications, all based on the same metro styles and one start properly (window shows) but the second shows just in Task Manager.

I'm running my app always on Win10 with .Net 4.6.1+, because I'm using in app .Net 4.6.1.

Have you any suggestions? Maybe I'm missed

回答1:

Have you tried procmon.exe to verify whats going on?

I had the similar issue and figured out with procman. and the issue was a missing dll which exists in my machine but not on other machine.

  1. Install procmon.exe from https://docs.microsoft.com/en-us/sysinternals/downloads/procmon
  2. run the procmon.exe and add filter(process name contains ). press add.
  3. Start your app
  4. Verify the procman entries and look for FileNotFound/PathNotFound in Result column. Hope you will find the root cause here.