Code Sample Summary

This SDK provides a set of samples that show how you can use the interfaces provided with this SDK. You can find four DTCs in the Visual Basic 6.0 project, VBSample. Another DTC is in the Visual C++ project 6.0, VCSample.

You can either open the sample projects to view the code or you try using the compiled versions provided in the bin directory. To use the Visual Basic samples, you need to register them by running the registration file also provided in the bin directory.

Note   If you installed this SDK in a directory other than the default, you need to modify the registration file to reflect the new directory otherwise, the registration fails.

The following table summarizes these samples.

Purpose Sample
Publishes a choice. VBSample.SourceDTC
Subscribes to the choice published by the SrcDTC VBSample.SinkDTC
Subscribes to the choice published by the SrcDTC VCSample.SinkDTC
Exposes an object model created in the DTC's runtime text to Visual InterDev so that it appears in the VBSample.ObjectModelDTC
Launches Visual InterDev's Query Builder, URL Picker, and Color Picker from a DTC. VBSample.QueryBuilderDTC

The Visual C++ sample creates a DTC that uses the choice published by the DTC in the Visual Basic project. You need to add the publisher in addition to the subscriber in order to test the page. For more information, see Testing a DTC's Output.

For simplicity, these samples use an inline interface. An inline user interface is the graphical representation of the DTC within the hosting document such as a form or other object with controls that accept user input. When creating a DTC, use property pages instead for setting a DTC's properties. Although Visual InterDev 6.0 supports inline user interface, this is not a guarantee that all DTC hosts are required to support it now or in the future.

For more information about creating DTCs, see the following walkthroughs.