I'm interested in knowing what commands we shouldn't use when we create a dynamic command, this way we could skip them appropriately.
Here is my list so far:
ExportToAutoCAD
Undo
Save
This is required because Civil 3D appears to use transactions to trigger other objects to make sure they are up to date. Civil 3D doesn't always commit the transactions, but opens them anyways. For instance if you save the drawing Civil 3D sometimes goes and makes sure the drawing is up to date and opens a bunch of transactions. The OnObjectModified code is then triggered. In the save condition if we then go and run our code to update objects that where open we end up opening and closing transactions that make it impossible for a user to create datashortcuts. Other instances such as ExportToAutoCAD it causes Civil 3D to crash since we are trying to modify objects Civil 3D is actively trying to explode multiple times and our program can get in the way.
Or is there a way to see if Civil 3D ultimately commits the transactions so we could realistically see if anything in fact changed. It would be cool if I didn't have to track commands that are run and a flag was available to see if Civil 3D really changed something and hence would need to run the code to update the dynamic objects. Although since most of the API team is no longer working on the Civil 3D API I won't hold my breath for that one.
Hi,
just as a guess, but always type of critical:
_PURGE
_AUDIT
- alfred -
Hi Civil Reminders,
First of all, I would suggest you to log a change request for this - "Other instances such as ExportToAutoCAD it causes Civil 3D to crash ". Please give the details when you submit this issue.
On the dynamic command issue, I don't see we have any such list, sorry. We might have to build it by try & check.
Thanks,
How did Autodesk solve this problem? http://blog.civil3dreminders.com/2012/12/data-shortcut-blues.html It's essentially the same issue I'm running into.
Civil Reminders,
I am going to check with my colleagues on this and request them to update / comment here on the same.
Thanks,