Solved

Visio 2013 COMMENTS PANE commandbar: how to display via VBA?

Posted on 2016-07-21
4
53 Views
Last Modified: 2016-07-26
I need to control the visibility of the visio 2013 COMMENTS PANE.

Application.CommandBars("Commenting").Visible = False or True
      - works fine, IF the pane has already been displayed whilst the file is currently open. Otherwise, Application.CommandBars("Commenting").Visible <--- gives an error.

I want to achieve the vba equivalent of clicking the ribbon/REVIEW/COMMENTS PANE button, then I can control.visibility thereafter.
When I click the ribbon/REVIEW/COMMENTS PANE button, there is no signal in the Developer/Event monitor.

My fall-back position is to use vba On Error to detect the error of attempting to re-set the visibility of Application.CommandBars("Commenting") and then use MsgBox to ask the user to open the Comments Pane.

Thanks
Kelvin
0
Comment
Question by:Kelvin4
  • 2
4 Comments
 
LVL 48

Accepted Solution

by:
Rgonzo1971 earned 500 total points
Comment Utility
HI,

Unfortunately, I cannot see a command to open the Comments pane
https://msdn.microsoft.com/en-us/library/office/ff768010.aspx

unlike reviewer
Visio.Application.DoCmd (visCmdTaskPaneReviewer)   '1939

Regards
0
 

Author Closing Comment

by:Kelvin4
Comment Utility
Hi Rgonzo,
Thanks for your comment; the reference to the Visio DoCmd/DOCMD Commands was especially useful.

I also looked at several other faint cmdBar candidates for a 'Comments pane', and found none.

So have installed my fall back of 'On Error' testing if the Comment Pane has been launched, and if not, using the error handler to direct the user to launch it manually..

Cheers,
Kelvin
0
 
LVL 30

Expert Comment

by:Scott Helmers
Comment Utility
With grateful thanks to fellow Visio MVP, John Goldsmith, here is a much more graceful solution to your problem:
     Application.DoCmd(1942)
toggles the Comments pane.

So, Rgonzo's approach was exactly correct -- but this particular command is undocumented.

How did John Goldsmith discover it? He turned on the EventMonitor and watched as he opened and closed the Comments pane.

Should have thought of that myself...
0
 

Author Comment

by:Kelvin4
Comment Utility
Crickey - I should have seen it too!
Now I can clean up my act and send you my draft 'Article'.

Many thanks to you and John
- Kelvin
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

The Question Several times in recent years, someone has posted a question at EE asking whether they could display the Windows directory structure – folders and subfolders – using Visio. When one person specifically asked about displaying directory …
The ability to add structure to Visio diagrams using containers, lists and callouts is one of my favorite features in Visio 2010. In this article we’ll examine containers. We’ll explore lists (http://www.experts-exchange.com/Microsoft/Applications/M…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now