Checknames option
-
The InsertObject api has a "checknames" option.
BaseDocument.InsertObject(op[, parent=None, pred=None, checknames=False])
I am missing this option with for example "InsertUnderLast()"
GeListNode.InsertUnderLast(obj)
What is the best way to get unique names for an object?
-Pim
-
Hi @Pim,
InsertObject allows you to achieve the same things with
parent
andpred
parameter.
You can get the last child of an object with GeListNode.GetDownLast.Now according to your request, keep in mind a GeListNode is not something related to a document, so it can be in a document but it's not mandatory, and it's why InsertObject get the
Checknames
parameter since it can check for all objects within the document.Hope it answers to your question,
Cheers,
Maxime. -
Works great, thanks.
-Pim