In the Workspace window, select the Class View tab, right-click the tree item
COM_VC_BankSoft.BSoftFin
classes, and choose New ATL Object from the local menu that appears.
Highlight the Objects item in the left list box and select
Simple Object
from the list of object types.
Click Next.
In the Short Name field, enter a short name for the class you want to create.
In the BankSoft example, use the name
BSoftFin
, since you are developing a financial function for the fictional company BankSoft. As you type into the Short Name field, the wizard fills in suggested names in the other fields.
Enter the programmatic identifier for the class.
In the BankSoft example, change the ProgID (programmatic identifier) field to
COM_VC_BankSoft.BSoftFin
.
A programmatic identifier, or ProgID, is the human-readable name for a class. Internally, classes are identified by numeric CLSID's. For example:
{33B17632-1D9F-11D1-8790-0000C044ACF9}
The standard format of a ProgID is
Project.Class[.Version]
. In the Designer, you refer to COM classes through ProgIDs.
Select the Attributes tab and set the threading model to
Free
, the interface to
Dual
, and the aggregation setting to
No
.
Click OK.
Now that you have a basic class definition, you can add a method to it.