Solved

Reading from the registry...

Posted on 1998-12-16
7
129 Views
Last Modified: 2010-07-27
I need to get all the sub-entries from an entry in the registry.
Example:
In my "HKEY_CLASSES_ROOT\Word.RTF.8\shell", the sub-entries is:
-New
-open
-print
-printto
-VirusScan

But I need to get(find/extract) them using code. How do I do that?
0
Comment
Question by:Olli083097
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
  • 2
7 Comments
 
LVL 4

Expert Comment

by:Chizl
ID: 1450712
'to get registry keys use:
Declare Function RegEnumKeyEx Lib "advapi32.dll" _
    Alias "RegEnumKeyExA" (ByVal hKey As Long, _
    ByVal dwIndex As Long, ByVal lpName As String, _
    ByVal cbName As Long) As Long

'to get values use:
Declare Function RegEnumValue Lib "advapi32.dll" _
    Alias "RegEnumValueA" (ByVal hKey As Long, _
    ByVal dwIndex As Long, ByVal lpValueName As String, _
    lpcbValueName As Long, lpReserved As Long, _
    lpType As Long, lpData As Byte, lpcbData As Long) _
    As Long
0
 
LVL 4

Expert Comment

by:Chizl
ID: 1450713
If you need more just ask
0
 
LVL 10

Expert Comment

by:caraf_g
ID: 1450714
Olli, I asked a very similar question myself recently and had good answers from both Mirkwood and Waty: - here's the URL

http://www.experts-exchange.com/topics/comp/lang/visualbasic/Q.10108254

You'll find it most helpful.
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:Olli083097
ID: 1450715
caraf_g: Your code was just what I needed! If you want the points, the just answer the question...!
0
 
LVL 4

Expert Comment

by:Chizl
ID: 1450716
So you wanted the application written for you not told what you can use..  Ok what ever floats your boat.  What he showed you is using the API I told ya to use.
0
 

Author Comment

by:Olli083097
ID: 1450717
Chizl: If it were possible to split the pionts on two persons I would have done it... But he gave me exactly what I needed + a lot more usefull code! Sorry...!
0
 
LVL 10

Accepted Solution

by:
caraf_g earned 50 total points
ID: 1450718
Olli, here's a token answer. Thanks. Sorry for the late reply I sadly had to go on holidays. O woe!
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
This article describes how to use a set of graphical playing cards to create a Draw Poker game in Excel or VB6.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question