高级会员
注册日期: 06-11
帖子: 14579
精华: 1
现金: 224494 标准币
资产: 234494 标准币
|
【转帖】objectarx&dummies教程(三b)——minimum application using arxwizard
objectarx&dummies教程(三b)——minimum application using arxwizard
objectarx&dummies教程(三b)——minimum application using arxwizard
class 3b - minimum application using arxwizard
hello,
on previous class i have presented the step by step way to create a minimum application by hand. of course there is a easier way to do that but i think is very important that you understand correctly things that are behind the scenes.
this time we will use the arxwizard tool which is provided by autodesk through objectarx sdk. if you go to the \utils folder you will find the install program. go ahead, install it and allow live update to run at the first time. do this with your visual studio .net closed.
after you install it, open visual studio.net, open file menu and start a new project. the following dialog will appear and you will find a new node inside visual c++ projects folder which is called autodesk. select this node and the objectarx/dbx/omf project icon will appear at the right side as following:
fill out the name field and specify the desired location to create the new project. click ok to continue. the following dialog will appear:
this dialog presents the steps to setup your new project. the first page, called overview, shows some information and give you the opportunity to inform your rds (registered developer symbol). this label will be used to prefix anything that your code could implement and could conflict with other third-party applications. to allow this prefix to be unique, autodesk provides (through adn subscriptions) a way to register your prefix and inform other adn members. even you are note an adn member you should create your own rds. use your initials, your 3 name first chars or any other name you find clear and useful.
the next step is to choose your desired application type. as i have mentioned before, arxwizard suggests the arx / dbx types which are basically the separation of interfaces and custom classes. more details about the main differences between arx and dbx can be found at objectarx documentation. this time we will choose the objectarx option as follows:
the next step is about additional sdk support which allows you to extend basic objectarx features to an specific autodesk vertical. there are two options:
omf support: this is the sdk extension for autodesk architectural desktop (aka adt) which contains specific features that could be used if you plan to develop an objectarx application to run inside adt;
map api support: this is the sdk extension for autodesk map which contains extra features to be used if you plan to develop a map objectarx application.
in our case, we will develop an objectarx application targeting plain (or vanilla) autocad so leave both blank.
the next step is to specify mfc support. as i mentioned before we will use mfc extension dll project type. this dialog also offers the option to enable autocad mfc extension support which will allow you to use specific autocad controls like linetype combo boxes, color combo boxes, dockable dialogs, etc. this is pretty handy once those controls are not so simple to implement from scratch. select extension dll and enabled autocad mfc support:
the last step is dedicated to com related stuff. objectarx supports com implementations on both server and client sides. as com programming is very complex and is beyond this course scope so i will not cover it.
leave the options on the not a com server and none. click finish to proceed.
now you can open the project files and see what the arxwizard has done for you. there are a lot of differences between the project we have created on previous class and the present project because arxwizard use different implementations using handy classes. we will cover these features several times with our upcoming samples on the next classes.
compile and build the project and try to load the resulting objectarx application inside autocad. you probably will be able to successfully load it.
|