Sparx Systems Forum

Enterprise Architect => Automation Interface, Add-Ins and Tools => Topic started by: Boron on July 29, 2011, 04:15:55 pm

Title: Apply and Release User Lock within script
Post by: Boron on July 29, 2011, 04:15:55 pm
Hello,
I did not find methods in the Automation API to apply and release user locks of model elements.

The purpose of my script is to find all elements containing a special tagged value and delete that tagged value.
As our model has "enabled security" the deleting can only happen when the element is locked for me, when I am running that script.
Instead of locking the whole model (about 20 users are working at the same time) I though of only locking the current element, delete the tag and unlock the element. Then move to the next element.
The other users wouldn't even notive that the script was executed.

Thanks for any idea.
Title: Re: Apply and Release User Lock within script
Post by: Geert Bellekens on July 29, 2011, 04:50:12 pm
How about Element.ApplyUserLock() and Element.ReleaseUserLock()?

Geert