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. ATL / WTL / STL
  4. SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\

SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\

Scheduled Pinned Locked Moved ATL / WTL / STL
windows-adminhelpquestion
5 Posts 3 Posters 3 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.
  • V Offline
    V Offline
    VeganFanatic
    wrote on last edited by
    #1

    So I am digging around deep in the registry So far so good, but I need to access specifics for each subkey

    	for (i=0; i<cSubKeys; i++)  { 
    		cbName = MAX\_KEY\_LENGTH;
    		retCode = RegEnumKeyEx(hKey, i,	achKey, &cbName, 0, 0, 0, &ftLastWriteTime); 
    		if (retCode == ERROR\_SUCCESS) {
    			RegQueryValueEx(hKey,L"DisplayName",NULL,NULL,(LPBYTE) lpData, &buffersize);
    			applist.push\_back(lpData);
    		}
    	}
    

    Anyway all I get are a bunch of "-" so am I getting the right type etc?

    http://www.contract-developer.tk

    L 1 Reply Last reply
    0
    • V VeganFanatic

      So I am digging around deep in the registry So far so good, but I need to access specifics for each subkey

      	for (i=0; i<cSubKeys; i++)  { 
      		cbName = MAX\_KEY\_LENGTH;
      		retCode = RegEnumKeyEx(hKey, i,	achKey, &cbName, 0, 0, 0, &ftLastWriteTime); 
      		if (retCode == ERROR\_SUCCESS) {
      			RegQueryValueEx(hKey,L"DisplayName",NULL,NULL,(LPBYTE) lpData, &buffersize);
      			applist.push\_back(lpData);
      		}
      	}
      

      Anyway all I get are a bunch of "-" so am I getting the right type etc?

      http://www.contract-developer.tk

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

      What are the types of lpData and applist?

      The best things in life are not things.

      V 1 Reply Last reply
      0
      • L Lost User

        What are the types of lpData and applist?

        The best things in life are not things.

        V Offline
        V Offline
        VeganFanatic
        wrote on last edited by
        #3

        I added another layer of hKey lpData is char* applist is CString I got it figured out with a lot more code needed

        http://www.contract-developer.tk

        L M 2 Replies Last reply
        0
        • V VeganFanatic

          I added another layer of hKey lpData is char* applist is CString I got it figured out with a lot more code needed

          http://www.contract-developer.tk

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

          Are you sure that lpData is big enough to hold the returned value? What is the value of buffersize when you call the query function? Also, I do not see a push_back() method for either CString or CStringT classes; are you sure this is what you mean?

          The best things in life are not things.

          1 Reply Last reply
          0
          • V VeganFanatic

            I added another layer of hKey lpData is char* applist is CString I got it figured out with a lot more code needed

            http://www.contract-developer.tk

            M Offline
            M Offline
            MicroVirus
            wrote on last edited by
            #5

            I'm guessing both lpData as applist need to be wide (unicode). You are using the wide version of RegQueryValueEx so for string values you are (I think) returned the unicode/wide version.

            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