The SDK contains libraries, header files, documentation and samples for AutoCAD Mechanical APIs.
ObjectARX can be downloaded from http://www.autodesk.com/objectarx
The ObjectARX include and library directories are specified in “\acadmapi\inc\acadmapi_CommonCfg.vsprop” and “\mcadapi\inc\mcadapi_CommonCfg.vsprop” files for the samples in ACADMAPI and MCADAPI respectively. Rename these directories accordingly if ObjectARX is installed in a different location from SDK.
The MCADAPI is removed, and the libraries and header files for Structure APIs are moved to ACADMAPI. Existing applications using Structure APIs will need to change include and library directories to “ACADMAPI\inc\” and “ACADMAPI\lib-win32\” or “ACADMAPI\lib-x64\”.
The API libraries are built using Microsoft® Visual Studio® 2008 and Visual C++® version 9.0. Existing applications will need to be rebuilt using Microsoft® Visual Studio® 2008 SP1.
The following ObjectARX virtual functions have been changed to sealed functions, and the corresponding protected functions with “sub” prefix have been added.
These functions in AutoCAD Mechanical API classes have been replaced with the corresponding protected functions with “sub” prefix.
For more details on these changes, please refer to ObjectARX Migration Guide, which can be found in "ObjectARX\docs\arxxmg.chm".
See the AutoCAD Mechanical C++ API Reference Guide for information on the new default parameter.
If your custom ARX application uses any derived classes from the API classes, then you should unload your ARX before exiting AutoCAD Mechanical. This is because when AutoCAD Mechanical shuts down, the API base classes will be unloaded before your custom application unloads. An example of such application is the sample application in “\acadmapi\sample\newstd\arrow”, which implements TestStandard class that derives from AcmStandardISO class.
After calling the function, ami2DSGetDefHideSituations() or ami2DSGetDefComplexHideSituations() to get AmiHideSituationKey or AmiComplexHideSituationKey respectively, you have to call amiRefocusKey() to set geometry path in this key to the specified occurrence before calling amiHighlight() on this key.
In the function, setSymbolDefaults() for each symbol classes, some of the common properties, such as color, linetype, linetype scale, visibility, layer, lineweight and plot style name will not be set to the default values if you have explicitly set them.
If you are using API to close the document and using the API in mcadapi, then you have to free AmiObjectKey object by calling amiEraseKey() before closing the document.
The function, deepclone() may not work properly for symbols, part reference, standard part and fits list in dimension.
The function, wblock() may not work properly for balloon, parts list and standard parts.
You can use ObjectARX to open a drawing file in AutoCAD Mechanical, and use AutoCAD Mechanical APIs to query the custom objects in the non-working database. There may be problem if you use AutoCAD Mechanical APIs to edit the custom objects in the non-working database.
In the function AcmBOMManager::importBOM, when set override Boolean parameter to false, the import will end at that point if a matching BOM item already exists in the BOM table. The test of a match is based on the handle value specified in the BOMKEY column.
To use the function, AcmBOMManager::setBomProperties() for switching the BOM table mode for a drawing with xref, you have to surround this function with cache activation by using the functions, AcmBOMManager::activateMainCache and AcmBOMManager::deactivateMainCache().
To use the function, AcDbDatabase::readDwgFile() to open a non-working database, you have to start a transaction first.
If there are xref drawings attached to a non-working database, then for xref databases to be loaded and resolved, the application must explicitly call the function, acdbResolveCurrentXRefs(). This will ensure that all the xref databases are properly loaded. If the xrefs needs to be redirected, then XLOADCTL needs to be set to 1 prior to calling acdbResolveCurrentXRefs, otherwise the database will not be properly initialized.
To use the function, amiGetDrawingType() in a non-working database, the non-working database must be created without associating to the current document. When create AcDbDatabase object, in the AcDbDatabase constructor, you need to set the second parameter, noDocument to true.
To use the function, amiGetKeyFromId() in a non-working database, you have to open a transaction in the non-working database.