( Index )

Brief Information about the May 2000 CSIG Meeting

WStart--- List the registry startup tasks.
Sample Output

Author: Bruce Arnold

Welcome to the C++ Users Group for May 2000.
Last month we investigated the Windows 98/Windows NT registry and demonstrated some simple API commands for accessing registry values. The program was called WinStart. It presented a list of start-up programs that ran every time the computer was booted.

The program was barely more than a command box program. It simply created a data file and then called the notepad application to present the data on the screen.

This month's program will be more sophisticated in that we will use the Microsoft Foundation Classes (MFC) Document View Architecture. This allows the presentation of the startup information on the screen without having to call any external program.

The Visual C++ application generator will create a Single Document Interface (SDI) which includes a document, frame, and view elements. We will discuss how to modify these elements at meeting this Tuesday. (3rd Tuesday of the month as usual.)

	for (dwIndex=0; ; ++dwIndex)
	    cbName = BUFFSIZE;
	    cbData = BUFFSIZE;
 	    code2 = RegEnumValue( 
		hKey,		    // handle of key to query
		dwIndex,	    // index of subkey to enumerate
		Name,		    // address of buffer for value string
		&cbName,	    // address for size of value buffer
		NULL,		    // reserved
		&Type,		    // address of buffer for type code
		Data,		    // address of buffer for value data
		&cbData		    // address for size of data buffer
	    if (code2 != ERROR_SUCCESS)
		if (code2 == ERROR_NO_MORE_ITEMS) // This is expected.
		else if (code2 == ERROR_ACCESS_DENIED) 
		    MessageBox( NULL, Name, 


"Random Access" questions start at 7:30 Tuesday night.


Source Code Files

For help, email me at b a r n o l d @ i e e e . o r g
Back to C++ Main Page