The most efficient way to start a Tool Palette application is to use the ObjectARX wizard. The procedures in this section use the ObjectARX wizard to handle most ObjectARX setup tasks. You can install this wizard from the AutoCAD Developer Center.
After the wizard is installed, a new icon for ObjectARX C++ applications appears in Visual Studio's dialog box when you start a new project. This icon launches the ObjectARX wizard. The wizard provides options for creating several types of Autodesk projects. It also lets you set MFC, COM, and ATL options, as you would with a Microsoft project wizard. A project generated by the ObjectARX wizard modifies Microsoft's default project setups to resolve conflicts between ObjectARX or ObjectDBX module structure and Microsoft requirements. The wizard also installs permanent UI toolbars in Visual Studio, additional templates, and boilerplate code. These tools hide most of the complexity of setting up an ObjectARX project.
You now have a project that combines ATL, the MFC framework, and the standard ObjectARX application infrastructure. The ObjectARX wizard adds a class to handle per-document data. In this basic project you do not need to store document data, so you should remove this unnecessary code.
#include "DocData.h" //----- Your document specific data //----- Declare it as an extern here so that it becomes available // in all modules extern AcApDataManager<CDocData> DocVars ;