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
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. C#
  4. Remove Vista security notice

Remove Vista security notice

Scheduled Pinned Locked Moved C#
csharpsecurityquestion
12 Posts 4 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.
  • G Offline
    G Offline
    Genbox
    wrote on last edited by
    #1

    Hi. I wanted to remove Vista security notification balloon that pops up when you deactivate UAC (User access control). I need to do this in an application written in C#, I can easily do this in a cmd, but it does not seem to work in C#. I write this in the CMD: REG DELETE "HKCR\CLSID\{FD6905CE-952F-41F1-9A6F-135D9C6622CC}" /f So I created this C# code: CreateProcess("reg.exe", @"DELETE \"HKCR\CLSID\{FD6905CE-952F-41F1-9A6F-135D9C6622CC}\" /f"); Create process creates a new process with reg.exe as an application and the delete as argument. That does not work. Any ideas?

    C H G 3 Replies Last reply
    0
    • G Genbox

      Hi. I wanted to remove Vista security notification balloon that pops up when you deactivate UAC (User access control). I need to do this in an application written in C#, I can easily do this in a cmd, but it does not seem to work in C#. I write this in the CMD: REG DELETE "HKCR\CLSID\{FD6905CE-952F-41F1-9A6F-135D9C6622CC}" /f So I created this C# code: CreateProcess("reg.exe", @"DELETE \"HKCR\CLSID\{FD6905CE-952F-41F1-9A6F-135D9C6622CC}\" /f"); Create process creates a new process with reg.exe as an application and the delete as argument. That does not work. Any ideas?

      C Offline
      C Offline
      Christian Graus
      wrote on last edited by
      #2

      Yeah, try writing some code that accesses the registry directly instead of trying to duplicate your command line code.

      Christian Graus Please read this if you don't understand the answer I've given you "also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )

      G 1 Reply Last reply
      0
      • G Genbox

        Hi. I wanted to remove Vista security notification balloon that pops up when you deactivate UAC (User access control). I need to do this in an application written in C#, I can easily do this in a cmd, but it does not seem to work in C#. I write this in the CMD: REG DELETE "HKCR\CLSID\{FD6905CE-952F-41F1-9A6F-135D9C6622CC}" /f So I created this C# code: CreateProcess("reg.exe", @"DELETE \"HKCR\CLSID\{FD6905CE-952F-41F1-9A6F-135D9C6622CC}\" /f"); Create process creates a new process with reg.exe as an application and the delete as argument. That does not work. Any ideas?

        H Offline
        H Offline
        Harvey Saayman
        wrote on last edited by
        #3

        id just remove vista :) hehe

        Harvey Saayman - South Africa Junior Developer .Net, C#, SQL

        you.suck = (you.passion != Programming)

        1 Reply Last reply
        0
        • G Genbox

          Hi. I wanted to remove Vista security notification balloon that pops up when you deactivate UAC (User access control). I need to do this in an application written in C#, I can easily do this in a cmd, but it does not seem to work in C#. I write this in the CMD: REG DELETE "HKCR\CLSID\{FD6905CE-952F-41F1-9A6F-135D9C6622CC}" /f So I created this C# code: CreateProcess("reg.exe", @"DELETE \"HKCR\CLSID\{FD6905CE-952F-41F1-9A6F-135D9C6622CC}\" /f"); Create process creates a new process with reg.exe as an application and the delete as argument. That does not work. Any ideas?

          G Offline
          G Offline
          Genbox
          wrote on last edited by
          #4

          By the way, I did also try another way: RegistryKey key = Registry.ClassesRoot.OpenSubKey("CLSID", true); key.DeleteSubKeyTree("{FD6905CE-952F-41F1-9A6F-135D9C6622CC}"); but it tells me that the subkey does not exist. I tried to print out all the subkeys: foreach (string str in key.GetSubKeyNames()) { Console.WriteLine(str); } Every key comes out.. so i'm in the right place, but the key I need does not show.

          C 1 Reply Last reply
          0
          • C Christian Graus

            Yeah, try writing some code that accesses the registry directly instead of trying to duplicate your command line code.

            Christian Graus Please read this if you don't understand the answer I've given you "also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )

            G Offline
            G Offline
            Genbox
            wrote on last edited by
            #5

            That was fast. I already tried that. Se my other reply.

            1 Reply Last reply
            0
            • G Genbox

              By the way, I did also try another way: RegistryKey key = Registry.ClassesRoot.OpenSubKey("CLSID", true); key.DeleteSubKeyTree("{FD6905CE-952F-41F1-9A6F-135D9C6622CC}"); but it tells me that the subkey does not exist. I tried to print out all the subkeys: foreach (string str in key.GetSubKeyNames()) { Console.WriteLine(str); } Every key comes out.. so i'm in the right place, but the key I need does not show.

              C Offline
              C Offline
              Christian Graus
              wrote on last edited by
              #6

              If the key does not exist, then you've done it, right ? I have no idea if what you're trying to do work. But, the code is right.

              Christian Graus Please read this if you don't understand the answer I've given you "also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )

              G 1 Reply Last reply
              0
              • C Christian Graus

                If the key does not exist, then you've done it, right ? I have no idea if what you're trying to do work. But, the code is right.

                Christian Graus Please read this if you don't understand the answer I've given you "also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )

                G Offline
                G Offline
                Genbox
                wrote on last edited by
                #7

                I think it's because Vista can do magic. At least it seems so. ---- C:\Users\Mads\Desktop>Rege.exe Disable security notifications C:\Users\Mads\Desktop>Rege.exe Disable security notifications Unhandled Exception: System.ArgumentException: Cannot delete a subkey tree because the subkey does not exist. at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource) at Microsoft.Win32.RegistryKey.DeleteSubKeyTree(String subkey) at Rege.Program.DisableSecurityNotifications() at Rege.Program.Main(String[] args) ---- So it does get deleted. But then i fire up regedit and see for my self. And there it is. I can even edit it's values and create new subkeys in it. I tried restarting, and the subkey is still there in regedit.

                G C 2 Replies Last reply
                0
                • G Genbox

                  I think it's because Vista can do magic. At least it seems so. ---- C:\Users\Mads\Desktop>Rege.exe Disable security notifications C:\Users\Mads\Desktop>Rege.exe Disable security notifications Unhandled Exception: System.ArgumentException: Cannot delete a subkey tree because the subkey does not exist. at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource) at Microsoft.Win32.RegistryKey.DeleteSubKeyTree(String subkey) at Rege.Program.DisableSecurityNotifications() at Rege.Program.Main(String[] args) ---- So it does get deleted. But then i fire up regedit and see for my self. And there it is. I can even edit it's values and create new subkeys in it. I tried restarting, and the subkey is still there in regedit.

                  G Offline
                  G Offline
                  Genbox
                  wrote on last edited by
                  #8

                  I found someting. When i delete the key: HKEY_CLASSES_ROOT\CLSID\{FD6905CE-952F-41F1-9A6F-135D9C6622CC} it deletes the key: HKEY_CLASSES_ROOT\Wow6432Node\CLSID\{FD6905CE-952F-41F1-9A6F-135D9C6622CC} I'm running 64bit Vista. I guess they made it that way, so that Vista 64bit would be more backwards compatable.

                  1 Reply Last reply
                  0
                  • G Genbox

                    I think it's because Vista can do magic. At least it seems so. ---- C:\Users\Mads\Desktop>Rege.exe Disable security notifications C:\Users\Mads\Desktop>Rege.exe Disable security notifications Unhandled Exception: System.ArgumentException: Cannot delete a subkey tree because the subkey does not exist. at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource) at Microsoft.Win32.RegistryKey.DeleteSubKeyTree(String subkey) at Rege.Program.DisableSecurityNotifications() at Rege.Program.Main(String[] args) ---- So it does get deleted. But then i fire up regedit and see for my self. And there it is. I can even edit it's values and create new subkeys in it. I tried restarting, and the subkey is still there in regedit.

                    C Offline
                    C Offline
                    Christian Graus
                    wrote on last edited by
                    #9

                    Oh - I think if you try to access the registry without permission, it creates a copy you can play with. I reckon that's happening to you. Vista is a pile of crap

                    Christian Graus Please read this if you don't understand the answer I've given you "also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )

                    R G 2 Replies Last reply
                    0
                    • C Christian Graus

                      Oh - I think if you try to access the registry without permission, it creates a copy you can play with. I reckon that's happening to you. Vista is a pile of crap

                      Christian Graus Please read this if you don't understand the answer I've given you "also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )

                      R Offline
                      R Offline
                      Reelix
                      wrote on last edited by
                      #10

                      Christian Graus wrote:

                      Vista is a pile of crap

                      Agreed!!!

                      -= Reelix =-

                      G 1 Reply Last reply
                      0
                      • C Christian Graus

                        Oh - I think if you try to access the registry without permission, it creates a copy you can play with. I reckon that's happening to you. Vista is a pile of crap

                        Christian Graus Please read this if you don't understand the answer I've given you "also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )

                        G Offline
                        G Offline
                        Genbox
                        wrote on last edited by
                        #11

                        No, It is in fact a part of the registry that enables 32bit backwards compatebility. I compilled my application for 64bit instead of 32bit, and it deletes the correct subkey now.

                        1 Reply Last reply
                        0
                        • R Reelix

                          Christian Graus wrote:

                          Vista is a pile of crap

                          Agreed!!!

                          -= Reelix =-

                          G Offline
                          G Offline
                          Genbox
                          wrote on last edited by
                          #12

                          How insightful. Please go tell someone else about your feelings for Vista.

                          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