07-27-2023 05:24 PM
I would like to make an in-memory copy of a container at run time. I tried using Clone() and then setting the object to the clone, but this does not work.
I don't want to have to crawl the object, or use LV to process this.
Is there a reasonable way to do something like...
Locals.newsubProperty("newContainer",PropValType_Container,False,"",0x01)
Locals.newContainer.[clone/copy,duplicate]("Path to existing container")
08-01-2023 04:53 PM - edited 08-01-2023 04:56 PM
Hello,
I give a try, a get some result using something like:
Locals.SetPropertyObject("CloneOfContainer1", PropOption_InsertIfMissing, Locals.Clone("Container1", PropOption_NoOptions))
Assuming that Container1 is a container in Locals, this add a clone of Container1 into Locals, named CloneOfContainer1. Perhaps the PropOption_CopyAllFlags may be usefull as argument for the Clone method, but I don't know if it applies to your specific case (see PropertyOptions)
I attach my 'exploration' sequence file (TS16).
Hope this helps,