Hi,
is there an way to copy an DOM instance from an Low code app? We’re building an task app and want to easie clone an task and change maybe only the name and a few other parameters. Basically an save as new or copy instance option.
Gerwin van der Kamp [DevOps Enabler] Selected answer as best
Hi Gerwin,
Below example will get you started
var instances = domHelper.DomInstances.Read(DomInstanceExposers.Id.Equal(IdOfInstanceToCopy));
domHelper.StitchDomInstances(instances);var instance = instances.First();
instance.ID = new DomInstanceId(Guid.NewGuid());domHelper.DomInstances.Create(instance);
Gerwin van der Kamp [DevOps Enabler] Posted new comment
I just figured that out 🙂 thanks!
Hi Gerwin, I’ve adapted above example. There was a small issue where I used class DomDefinitionId instead of DomInstanceId for assigning a new ID to the instance.