Performance issue on parsing shapes

W

Walter Quirtmair

Hello,
I have rather large drawings with hundreds or thousands of shapes. For some
actions I have to find specific shapes, which have all well defined user
cell values.

We are using VS.NET C# and Visio 2003. Parsing through this drawings can
take really very, very long (up tho hours). The problem is that we don't
know which shapes have these cells set. We have not only to look for
top-shapes (groups) but also to sub-shapes in groups as well...

Is there any find mechanism or filter we can use in Visio to get specific
shapes? Do we really have to check each and every shape and its sub-shapes
individually?

Thank you for any help,
Walter
 
C

Chris Roth [ Visio MVP ]

Walter,

I can think of a couple of suggestions that might help you out.

GetResults is a function for getting many results from many cells from many
shapes in one automation call. Check out the developer reference on how to
use this.

CreateSelection (Page object and others) allows you to build a collection of
shapes, based on layers, masters, not-groups and other criteria. Perhaps
your search can be narrowed somehow.

Save the file as XML (.VXD) and let text/xml-parsing rip through the
document. I imagine this is faster than via automation.

--

Hope this helps,

Chris Roth
Visio MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top