Sparx Systems Forum

Enterprise Architect => Automation Interface, Add-Ins and Tools => Topic started by: jumbie on July 05, 2021, 08:49:55 pm

Title: refresh edit Linked Document window (tab) after LoadLinkedDocument
Post by: jumbie on July 05, 2021, 08:49:55 pm
Hi all,
I want to solve this problem:

1. With Artifact Document I have Linked Document opened for editing in the Tab window.

2. I start the script, at first I save the Linked Document to a temporary external docx file using SaveLinkedDocument

3. I perform some operations on this file using VBA by script

4. I return this file to the Linked Document using LoadLinkedDocument.

Everything works OK, just one "little" thing:

In the open editing window, this document will not be refreshed after loading from file
and there is the original content before processing.

I need either:

a) refresh the editing Tab window for Linked Document using a script - at the end of script after LoadLinkedDocument

b) or the script will close this Tab editing window so that the user has to reopen this window and this will refresh the contents of the window.

(I can delete the Linked Document by script, but it is dangerous operation) 

Any recommendations?

Thanks!

Title: Re: refresh edit Linked Document window (tab) after LoadLinkedDocument
Post by: Geert Bellekens on July 05, 2021, 09:13:59 pm
There are a few things to try


Geert
Title: Re: refresh edit Linked Document window (tab) after LoadLinkedDocument
Post by: jumbie on July 06, 2021, 02:54:42 am
Hi Geert,

with AdviseElementChange the user is notified that the document was changed by another user, and it is enough. 

Thanks !!!

(But I have another serious problem, it will be placed in another thread)

Jumbie