Share via


Visual Basic Concepts

Control Creation Recap

In order to introduce new concepts in the most natural order, the procedures in this chapter have not followed the normal sequence of steps for creating a new control.

Note   This topic is part of a series that walks you through creating a sample ActiveX control. It begins with the topic Creating an ActiveX Control.

When you create a new control, the steps you’ll generally follow are these:

  1. Determine the features your control will provide.

  2. Design the appearance of your control.

  3. Design the interface for your control — that is, the properties, methods, and events your control will expose.

  4. Create a project group consisting of your control project and a test project.

  5. Implement the appearance of your control by adding controls and/or code to the UserControl object.

  6. Implement the interface and features of your control.

  7. As you add each interface element or feature, add features to your test project to exercise the new functionality.

  8. Design and implement property pages for your control.

  9. Compile your control component (.ocx file) and test it with all potential target applications.

If your control component will provide more than one control, you should begin by deciding what controls the package will include. Your test project should have separate test forms for the individual controls, and at least one form that tests the controls together.

For More Information   General design issues for ActiveX components are discussed in "General Principles of Component Design" and "Debugging, Testing, and Deploying Components." Issues exclusive to ActiveX control creation, testing, packaging, and deployment are discussed in "Building ActiveX Controls" and "Creating Property Pages for ActiveX Controls."