0

I added an app.manifest to a C# Windows Forms project because I needed the .exe elevated. Worked fine. I deleted the manifest because I no longer needed the app elevated. I changed to create application without manifest in properties.Re_Built...the app still needs admin elevation to run. Works fine if I right-click run as admin. What gives?

3
  • Please describe the symptoms precisely. Your prose here is imprecise. Jan 2, 2014 at 20:06
  • 1
    its possible the manifest it still cached, i ran into something similar. and had to touch the exe with powershell, to change the create date. Jan 2, 2014 at 20:07
  • The app just dies unless it's run as admin. No errors at all..
    – cablehead
    Jan 2, 2014 at 20:13

1 Answer 1

0

The app just dies unless it is run as admin.

Well, despite what you say, it seems that your program carries out actions that do require elevation. Perhaps you write to a location that standard user does not have rights to. Or perhaps you write to registry keys under HKLM.

To get to the bottom of this you need to do some debugging. Find out what it is that your program does that requires elevation. Use the IDE debugger, or a tool like Process Monitor.

5
  • It will run fine in the IDE if I start VS as Admin. I'm not doing anything that requires elevation...it ran fine without elevation until I added the manifest and then deleted it.
    – cablehead
    Jan 2, 2014 at 20:36
  • The symptoms contradict you. Don't start VS as admin. Debug the app running as standard user. Bear in mind that we do not have your program at hand. Only you can debug it. Unless you provide an SSCCE. Jan 2, 2014 at 20:49
  • Thanks for your time. Its a giant solution..without Admin in VS it crashes at nonsense..
    – cablehead
    Jan 2, 2014 at 21:01
  • Form1 p = new Form1();
    – cablehead
    Jan 2, 2014 at 21:01
  • Like I said, your program is sensitive to elevation, in spite of what you think Jan 2, 2014 at 21:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.