C# - Excel格式更改事件 [英] C# - Excel format change event

查看:76
本文介绍了C# - Excel格式更改事件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


当我们点击excel中的任何格式化按钮(如Bold,Fill)时,是否有任何事件可以触发?

解决方案

Hello Richard,


Excel对象模型不提供任何具体的事件。作为一种解决方法,您可以考虑重新调整功能区控件,请参阅

Office Fluent功能区上的临时重新调整命令
以获取更多信息。


内置控件ID列表可以在以下文档中找到:


Office 2010帮助文件:Office Fluent用户界面控件标识符


Office 2013帮助文件:Office Fluent用户界面控件标识rs


Office 2016帮助文件:Office Fluent用户界面控件标识符


Hi,

Is there any event that can be fired when we click on any of the formatting buttons in excel(like Bold, Fill)?

解决方案

Hello Richard,

The Excel object model doesn't provide any specific events for that. As a workaround you may consider repurposing ribbon controls, see Temporarily Repurpose Commands on the Office Fluent Ribbon for more information.

The list of built-in control IDs can be found in the following documents:

Office 2010 Help Files: Office Fluent User Interface Control Identifiers

Office 2013 Help Files: Office Fluent User Interface Control Identifiers

Office 2016 Help Files: Office Fluent User Interface Control Identifiers


这篇关于C# - Excel格式更改事件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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