Editing the Consumer Resource File

To create a user interface for the consumer, you must modify the default dialog created by MFC AppWizard. In the dialog resource IDD_TESTPROV_DIALOG, you must add a Run button and two list boxes (for the two strings that will be returned from the provider).

In the Workspace window, in the ResourceView tab, open the IDD_TESTPROV_DIALOG resource.

To add the Run button

  1. From the Controls toolbar, select the button icon and drag it to the IDD_TESTPROV_DIALOG dialog box.

  2. Right-click on the button you just created and choose Properties.

  3. In the Properties dialog box, change the button caption to Run.

  4. Close the Properties dialog box.

To add a list box

  1. From the Controls toolbar, select the list box icon and drag it to the IDD_TESTPROV_DIALOG dialog box.

  2. Right-click on the button you have just created and choose Properties.

  3. In the Properties dialog box, select the Styles tab and clear the Sort check box.

  4. Close the Properties dialog box.

To complete the consumer, you must edit the code in the user record.

Back to Implementing an OLE DB Template Consumer