This sample demonstrates how to write a VBX control using MFC 2.0. This sample uses _USRDLL. This enables this sample to be used used by MFC and VB applications. Using _AFXDLL will restrict this sample to be used only by MFC applications. It is important that the MODEL, Property and Event structures be declared NEAR in order for this control to work correctly. It is also important that you create an object of a class derived from CWinApp. This allows some MFC initializations to take place. Depressing the left button inside the control when your application is executing will display a message box indicating the point of your mouse click. You can use AppStudio to set the properties of this control. You can use ClassWizard to manipulate CVBCtlWnd class if needed. For more information on _USRDLL and _AFXDLL refer to technote 33. P.S. The include files VBAPI.H and VBAPI.LIB are not included with this sample. In order to re-compile this sample, you will need this file. This file comes with the Visual Control Pack or VB PRO. If you are writing vbx controls, then you will need either of these packages.