You could just open multiple views on the same document, and move the objects you want to see in View2 into a separate layer. Views can choose which layers are visible.
See the Object Browser sample.
Multiple views in same document is not going to help for my application.
I was thinking create GoObjects array and copy all objects using Document.CopyTo.
Then create another document and use Document.CopyFromCollection function to paste all the objects.
Do you think my idea works or not.
You can just create a GoCollection and .Add the objects you want to it, then do the CopyFromCollection into the second document.
will make a copy of the first view’s document into the second one.
A wise old programmer taught me a long time ago… “any time you have two copies of something, one of them is eventually going to be wrong”.
I don’t envy you the task of keeping “one node in multiple documents” in sync.
<p style=“margin: 0cm 1.5pt 0.75pt; line-height: normal;” =“Msonormal”>If I use this method to create a copy of an
document. How can I preserve the GoLink attachments on the ports in the New
copied document?<?: prefix = o ns = “urn:schemas-microsoft-com:office:office” /><o:p></o:p>
That’s weird, I thought I had answered this.
<span =“Apple-style-span” style=": rgb248, 248, 252; “><span =“highlight”=”">CopyFromCollection will copy all the links and their connections to nodes.
I will have to dig deeper all my nodes and links is copied but the links is not attached to the ports. Any pointers? Except for the lose go links the copy is perfect.
The first thing to try is a call to GoDocument:TestSerialization() to check. (See the API reference).