WriteKey Method (Utility Control)
   Windows - Visual C++
   Description
   The WriteKey method writes a value 
   to the Windows registry, depending on the value of the IniType property.
   Syntax
   long result = WriteKey(LPCTSTR section, LPCTSTR entry);
The WriteKey syntax has these parts:
| Part | Description | 
| section | A String containing the section name of the Windows registry. | 
| entry | A String containing the entry name within the section. | 
| result | Return value. A long integer containing 0 if successful and 1 if not. | 
   Remarks
   The value of the IniType property
    determines whether the WriteKey method writes to the Windows 
   registry. If IniType is 0, it indicates that WriteKey should write to 
   the  initialization (.ini) file. If IniType is 1, it indicates that 
   WriteKey should write to the Windows registry. The IniValue property
    indicates either the initialization (.ini) file name or the Windows 
   registry key value that should be accessed, again depending on the 
   value of the IniType property.
Before WriteKey is called, the KeyValue property should be set to the value to be written.
See Also: ReadKey KeyValue IniValue IniType
Back to: Utility Methods