获取功能区控件的名称或ID [英] Get name or Id of a ribbon controls

查看:91
本文介绍了获取功能区控件的名称或ID的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在我的excel中有一个自定义的功能区控件,这个功能区是通过第三方c#add来开发的。如何使用VBA代码触发功能区按钮单击?网上的许多例子显示了这一点,但是我的第一个问题是我甚至不知道功能区的名称。我如何获得我感兴趣的功能区和功能区按钮的名称?

解决方案

我发现以下链接
如何获取功能区自定义标签ID?



进一步的阅读让我来到这个链接



http://www.wordarticles.com/Shorts/RibbonVBA/RibbonVBADemo.php



在下载部分我下载了具有VBA程序的单词模板,以阅读功能区,选项卡和按钮。它还有一个代码来触发/执行所选按钮。这个VBA函数也可以用于excel。


I have a custom ribbon control in my excel that ribbon is developed through 3rd party c# add in. How do I trigger a ribbon button click using VBA code? Many examples over the net show this but my first problem is I even don't know the name of the ribbon. How do I get the name of the ribbon and ribbon button i am interested in?

解决方案

I found this below link How to get Ribbon custom Tabs IDs?

further reading reached me to this link

http://www.wordarticles.com/Shorts/RibbonVBA/RibbonVBADemo.php

In the download section I downloaded the word template that has a VBA program to read the ribbon,tab and buttons. It also has a code to trigger/ execute the selected button. This VBA function can also be used for excel.

这篇关于获取功能区控件的名称或ID的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆