65.9K
CodeProject is changing. Read more.
Home

Registry Viewer

starIconstarIconstarIconstarIcon
emptyStarIcon
starIcon

4.93/5 (16 votes)

Jan 23, 2004

1 min read

viewsIcon

168232

downloadIcon

4287

An application to view Registry entries.

Sample Image - RegViewer.jpg

Introduction

I have noticed that some people are not able to use RegEdit because of not having administrator rights on machines running Windows NT/2K. We cannot see Registry values. So, I wrote a small RegViewer application to view Registry Entries. I know that many such utilities are available on the net.

Description

I have created a simple MFC application having Explorer style. Treeview shows Registry Keys on left side and listview shows Registry Key Values on right side.

I have written two functions:

  • void EnumRegistryKey(HKEY hKey, string sKeyName, vector< string >& ListEnumKey);
  • void EnumRegistryKeyValue(HKEY hKey, string sKeyName, vector< RegKeyDetail >& ListEnumKey);

Function EnumRegistryKeywill enumerate all Keys contained by parent Keys, i.e., hKey and sKeyName parameters of the function. hKey must be Reserved Key handles like HKEY_CLASSES_ROOT, HKEY_CURRENT_USER, HKEY_LOCAL_MACHINE etc. sKeyName parameter is Key Name.

Function EnumRegistryKeyValue will enumerate all Key Values contained by a Key. This function can read REG_SZ, REG_EXPAND_SZ, REG_MULTI_SZ, REG_BINARY, REG_RESOURCE_LIST, REG_RESOURCE_REQUIREMENTS_LIST, REG_FULL_RESOURCE_DESCRIPTOR and REG_DWORD type of Key Values.

History

  • 27th Jan 2004

    Modified to read and view REG_EXPAND_SZ and REG_MULTI_SZ, by double clicking Key Name.

Remarks

I am still working on this application. Very soon, I will update a newer version with more facilities.