Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. how to disable uac prompt programmatically

how to disable uac prompt programmatically

Scheduled Pinned Locked Moved C / C++ / MFC
helptutorial
5 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    shanmugarajaa
    wrote on last edited by
    #1

    Dear Friends, I have requirement to disable UAC prompt through programmatically. Please anyone help me on this. Thanks, S Shanmuga Raja

    L J 2 Replies Last reply
    0
    • S shanmugarajaa

      Dear Friends, I have requirement to disable UAC prompt through programmatically. Please anyone help me on this. Thanks, S Shanmuga Raja

      L Offline
      L Offline
      Lost User
      wrote on last edited by
      #2

      No. The UAC prompt is there to protect the owner of the PC.

      1 Reply Last reply
      0
      • S shanmugarajaa

        Dear Friends, I have requirement to disable UAC prompt through programmatically. Please anyone help me on this. Thanks, S Shanmuga Raja

        J Offline
        J Offline
        Jochen Arndt
        wrote on last edited by
        #3

        That is not possible for the current login session because it would defeat the purpose of UAC. You can change the setting using the registry but that requires a reboot to become active (see Enable or Disable UAC From the Windows Command Line[^]; it is for the command line but shows the registry settings to be changed).

        S 1 Reply Last reply
        0
        • J Jochen Arndt

          That is not possible for the current login session because it would defeat the purpose of UAC. You can change the setting using the registry but that requires a reboot to become active (see Enable or Disable UAC From the Windows Command Line[^]; it is for the command line but shows the registry settings to be changed).

          S Offline
          S Offline
          shanmugarajaa
          wrote on last edited by
          #4

          whether its possible to assign administrator right to my application though programmatically. So that I can set value 0 or 1 to EnableLUA in registry.

          J 1 Reply Last reply
          0
          • S shanmugarajaa

            whether its possible to assign administrator right to my application though programmatically. So that I can set value 0 or 1 to EnableLUA in registry.

            J Offline
            J Offline
            Jochen Arndt
            wrote on last edited by
            #5

            Assigning administrator rights to an application requires administrative privileges. So while it does not have these, you can't change it. And you can not elevate the privileges of a running process. You can use a manifest to specify that your application should run elevated, use the "runas" command or start other applications elevated from within your program. But in all these cases there will be a UAC prompt. UAC is there for a reason. It is a security feature. The user decides which level of security should be used. An application can not bypass these settings.

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups