The SDK contains libraries, header files, documentation and samples for AutoCAD Mechanical APIs.
Microsoft Visual Studio 2022 should be used when compiling projects for use with AutoCAD Mechanical 2025.
Refer to readme for ObjectARX for details on the changes.
-
If your custom ARX application uses a derived class from the API classes, unload your ARX before you exit AutoCAD Mechanical. This causes the API base classes to unload before your custom application does.
An example of such application is the sample application in \acadmapi\sample\newstd\arrow, which implements the TestStandard class, which is derived from the AcmStandardISO class.
-
After calling the function, ami2DSGetDefHideSituations() or ami2DSGetDefComplexHideSituations() to get AmiHideSituationKey or AmiComplexHideSituationKey respectively, you have to call amiRefocusKey() to set the 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().
-
When call the default constructor of AcmBalloon class, you have to associate a part ref by using AcmBalloon::setRowIds() or AcmBalloon::appendItem(). Otherwise it may result in a corrupted balloon.
-
AcmBalloon::SetRowIds() and AcmBalloon::appendItem() are used to associate balloon to the specified part reference. You should not change the part reference that is associated with a balloon. Therefore you should not call this function more than 1 time when creating a new AcmBalloon object. You should also not call this function when editing an existing AcmBalloon object.
-
You should not use AcmDatumTarget::getNewTarget() to change the datum target type after creating datum target. You should specify the target type in the constructor of AcmDatumTarget class.
-
When creating a AcmSymbol object, you should call addLeader() before calling attachGeomRef().
-
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.