Results 1 to 11 of 11

Thread: [RESOLVED] UAC Prompt

  1. #1

    Thread Starter
    Member
    Join Date
    May 2003
    Location
    Wisconsin
    Posts
    57

    Resolved [RESOLVED] UAC Prompt

    I am on VS 2012 and always open the devenv.exe as Administrator. I've been working on a VB application for several weeks now. At some point, I (apparently) unknowingly introduced some code that is causing Windows to produce a UAC prompt when I try to launch the EXE of my application.

    I'm just wondering if there is any way to hunt down the offending code? I made a copy of the project and started removing classes and deleting code until I was down to the bare bones of the app. But still it prompted UAC. I also searched and tried a number of different suggestions (including altering the requestedExecutionLevel in the Manifest options). No dice.

    This app has to be able to run via whatever user is logged in, and without requiring elevated privileges. And there is nothing that is writing to the registry, or Windows directory, or Program Files directories. If anyone could point me in the right direction, that would be very appreciated.

    Thanks in advance!

  2. #2
    Bad man! ident's Avatar
    Join Date
    Mar 2009
    Location
    Cambridge
    Posts
    5,390

    Re: UAC Prompt

    A user will always need to evaluate regardless if signed in as admin. Thats the whole point of security.

  3. #3
    Super Moderator Shaggy Hiker's Avatar
    Join Date
    Aug 2002
    Location
    Idaho
    Posts
    35,242

    Re: UAC Prompt

    Which OS are you running this on? Some are very strict with UAC, some don't have it at all, effectively (though those are fading out fast).
    My usual boring signature: Nothing

  4. #4
    Bad man! ident's Avatar
    Join Date
    Mar 2009
    Location
    Cambridge
    Posts
    5,390

    Re: UAC Prompt

    Oh i get it you are moaning when debugging no uac is run but a stand alone exe is.

  5. #5
    Still learning kebo's Avatar
    Join Date
    Apr 2004
    Location
    Gardnerville,nv
    Posts
    3,712

    Re: UAC Prompt

    Does it happen if you run devenv without admin privileges?
    Process control doesn't give you good quality, it gives you consistent quality.
    Good quality comes from consistently doing the right things.

    Vague general questions have vague general answers.
    A $100 donation is required for me to help you if you PM me asking for help. Instructions for donating to one of our local charities will be provided.

    ______________________________
    Last edited by kebo : Now. Reason: superfluous typo's

  6. #6

    Thread Starter
    Member
    Join Date
    May 2003
    Location
    Wisconsin
    Posts
    57

    Re: UAC Prompt

    Quote Originally Posted by Shaggy Hiker View Post
    Which OS are you running this on? Some are very strict with UAC, some don't have it at all, effectively (though those are fading out fast).
    Win 8.1 Pro.

    Quote Originally Posted by kebo
    Does it happen if you run devenv without admin privileges?
    Yep.


    Just to clarify, this application didn't always trigger a UAC prompt. It was only within the past several weeks of coding that something started causing it. Like I said, I removed code and references. And I checked other obvious things. Nothing got rid of the UAC prompt.

  7. #7
    Still learning kebo's Avatar
    Join Date
    Apr 2004
    Location
    Gardnerville,nv
    Posts
    3,712

    Re: UAC Prompt

    Step through your code in debug until the UAC pops up, then you have you guilty party. Right?
    Process control doesn't give you good quality, it gives you consistent quality.
    Good quality comes from consistently doing the right things.

    Vague general questions have vague general answers.
    A $100 donation is required for me to help you if you PM me asking for help. Instructions for donating to one of our local charities will be provided.

    ______________________________
    Last edited by kebo : Now. Reason: superfluous typo's

  8. #8

    Thread Starter
    Member
    Join Date
    May 2003
    Location
    Wisconsin
    Posts
    57

    Re: UAC Prompt

    Quote Originally Posted by kebo View Post
    Step through your code in debug until the UAC pops up, then you have you guilty party. Right?
    The Debugger doesn't even step into a single line of code before the UAC prompt comes up.

    In either case, I'm going to mark this as 'RESOLVED'. I figure it'll take me less time to fork off an old backup of the Project when it was working; and Copy/Paste code from the current, non-working Project into the new fork.

    Thanks!

  9. #9
    PowerPoster JuggaloBrotha's Avatar
    Join Date
    Sep 2005
    Location
    Lansing, MI; USA
    Posts
    4,284

    Re: UAC Prompt

    Quote Originally Posted by kebo View Post
    Step through your code in debug until the UAC pops up, then you have you guilty party. Right?
    The UAC prompt only opens before an app is ran, meaning once it's running, if it's an app that requires it, he'll have gotten the prompt before any code is able to be stepped through.

  10. #10
    Still learning kebo's Avatar
    Join Date
    Apr 2004
    Location
    Gardnerville,nv
    Posts
    3,712

    Re: UAC Prompt

    Quote Originally Posted by JuggaloBrotha View Post
    The UAC prompt only opens before an app is ran, meaning once it's running, if it's an app that requires it, he'll have gotten the prompt before any code is able to be stepped through.
    That's true if the UAC is for his app, but what about if the app is starting something that requires elevated privileges? Such as if his app is calling a installer. Wouldn't that then prompt the UAC?
    kevin
    Process control doesn't give you good quality, it gives you consistent quality.
    Good quality comes from consistently doing the right things.

    Vague general questions have vague general answers.
    A $100 donation is required for me to help you if you PM me asking for help. Instructions for donating to one of our local charities will be provided.

    ______________________________
    Last edited by kebo : Now. Reason: superfluous typo's

  11. #11
    PowerPoster
    Join Date
    Sep 2005
    Location
    Modesto, Ca.
    Posts
    4,548

    Re: [RESOLVED] UAC Prompt

    I've encountered two types of this problem. One is easily solved because there is a Checkbox on the UAC prompt that say "Don't show this prompt again". The other was to create a Short Cut and lunch the app by using the Short Cut. Not sure why that solved the problem but it did.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width