HC_Record_Profile_Source

void HC_Record_Profile_Source(char const *section, char const *filename)
void HC_Record_Profile_Source(char const section, char const filename)

Identifies the INI file name and section to use for evaluating profile strings.

This routine is typically the first routine called by a Microsoft Windows aware HOOPS program. It notifies HOOPS as to where to look for profile strings such as the one defined for HOOPS_PICTURE. If this routine is not called, HOOPS looks for its settings in the Registry.

By default, Hoops looks in the registry under HKEY_CURRENT_USERHOOPS for settings. HC_Record_Profile_Source was added to allow changing the “HOOPS” part of that. For instance

HC_Record_Profile_Source ("FOO", "REGISTRY");

would tell it to look in HKEY_CURRENT_USERFOO instead. A path under HKEY_CURRENT_USER can also be specified, such as “PTC\FOO”.

The change was to enhance HC_Record_Profile_Source to allow the program to specify a full registry path, such as

HC_Record_Profile_Source ("\\HKEY_LOCAL_MACHINE\\FOO", "REGISTRY");

which can be seen by all users.

This routine is only useful on Microsoft Windows. If called for HOOPS on any other platform, it is ignored unless sanity checking is enabled, in which case a warning message is issued.

HOOPS Visualize currently recognises:

  • HKEY_CLASSES_ROOT
  • HKEY_CURRENT_USER
  • HKEY_LOCAL_MACHINE
  • HKEY_USERS

…as valid roots. There are some others that have been added (starting with version 10.0) for completeness:

  • HKEY_PERFORMANCE_DATA
  • HKEY_CURRENT_CONFIG
  • HKEY_DYN_DATA

…with the minor caveat that WinCE doesn’t support them.

Parameters

section: The sectionheader, usually the application name, of the INI file. Passed by reference.

filename: The name of the .INI file. Passed by reference.