开发者

Any way to set png export resolution in Visio 2003?

I am trying to export a page from a Visio document to a p开发者_Go百科ng file using Visio 2003. The Export method works, but I haven't found any way to set the desired output resolution.

The documentation mentions what it uses the defaults, but nothing on how to change them:

The Export method uses the default preference settings for the specified filter and does not prompt the user for non-default arguments.

In Visio 2010, it is possible to set these properties via SetRasterExportSize, but that property isn't available in Visio 2003.

So, my question:

Is there any way to set the png output resolution in Visio 2003?


Not directly. The Export method for 2003/7 simply respects the last settings that were used via the UI (ie File / Save As from memory) for a given session.

One workaround suggested in Graham Wideman's book (Visio 2003 Developers Survival Pack) is to use the SendKeys method, although as he points out this is not a very robust option. For his book he created a COM component (DAKbdEventLib) that avoids some of the problems of SendKeys. I not sure if the book is still available (it's still very relevent to Visio 2010), but you could have a look here:

http://www.diagramantics.com/v11dsp/index.htm

As you point out the ability to control export settings via code, only appeared in the api in the 2010 version.

Hope that helps

Best regards

John

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜