CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    May 1999
    Posts
    226

    Using the registry

    I'm trying to write some code that will modify the registry so files can be opened with my program. After playing with the registry using regedit I figured out what I need to do but I can't figure out how to code it.

    First, I need to look at the value here:
    HKEY_CLASSES_ROOT\.html\(Default)
    on my computer it's "NetscapeMarkup"
    This is the first thing I can't get to work.

    Then, I take that value and combine it with HKEY_CLASSES_ROOT\ and \shell to get
    HKEY_CLASSES_ROOT\NetscapeMarkup\shell

    Then, I can add the options under the path. Such as edit, open, etc.
    What I want to do is add Edit\command\(Default) under HKEY_CLASSES_ROOT\NetscapeMarkup\shell if it's nots already there then set the value to the location of my program.
    I can't figure out how to do this either.

    Can anyone help me?

    Scott MacMaster
    ______________________
    http://welcome.to/scottweb

  2. #2
    Join Date
    May 1999
    Posts
    68

    Re: Using the registry

    Please check out RegOpenKey(),RegQueryValueEx() functions.


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

Featured