THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 20/02/2006 at 12:44, xxxxxxxx wrote:
User Information:
Cinema 4D Version: 9.5
Platform: Windows ;
Language(s) : C++ ;
---------
Hi!
I need to save some points arrays in my Plugin. Thus, I have used the CustomDataType functions and it works fine. Now, I try to add Undo actions. My question is simple : how use the BaseContainer::AddUndo(LONG type, void *data) when data points to a element of a CustomDataType?
If the variable with the type of my CustomDataType is called MyData and contains the element Vector *arr, when I type
BaseDocument *doc = GetActiveDocument;
doc->AddUndo(UNDO_CHANGE, MyType.arr);
Cinema4D crashes.
Is there an explanation or must I explain more about my code?
Thanks.