Visio Clipboard access

X

xargon

Hi everyone,

I would like to serialize the Visio clipboard data into XML. So basically
what I wanted to do was copy all data into clipboard and access it again
and save it as base64 into SolutionXML.

So, basically I used something like:

ActiveWindow.SelectAll
ActiveWindow.Selection.Copy

Dim do as New DataObject
do.GetFromClipboard

However, do.GetText does not work... What I would like to do is the get
the clipboard data as base64 text or something that I could embed into
XML.

Does someone have an idea on how to proceed with this?

Thanks,xargon
 
J

JuneTheSecond

II do not know why it does not work, then how would you like to use text
property of Visio shape?
 
C

Chris Roth [MVP]

Off the top of my head, I believe that the clipboard holds multiple formats,
ie: text, visio-shape, visio-shape-xml. You need to inspect the various
formats and figure out what the visio-shape-xml format is called, then get
that. Is there an argument for the GetFromClipboard function? I can't check
right now, and I'm not stating it very accurately, but I believe this is the
general method. Hopefully this will get you pointed in the right
direction...


Chris Roth
Visio MVP
 
J

JuneTheSecond

If there is one simple shape on the page, your code works.
So, one idea may be to run the code for each shape and for each child shape,
if the shape is grouped.
 

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