摘要:
这是一个根据用户需求给出的例子,用来改写“插入表格(I) ...”按钮的动作。我们可以以此引申为在Office中所有Button或CommandButton都可以用这样的方法改变动作。Ribbon Xml 内容如下: Ribbon Class 如下:using System;using... 阅读全文
摘要:
在使用反射的过程中如果发生“exception has been thrown to the target of an invocation”异常,那很有可能是被反射的Assembly中引用了其他Assembly而这些被引用的Assembly在主程序中没有被引用。欢迎访问我的主博客《许阳的红泥屋》 阅读全文
摘要:
在Word中用户可以通过UndoRecord来记录一组动作,并显示在撤销菜单内。这样可以让用户一次性删除大量的操作。下面的代码是在Visual Studio 2010, Word 2010 下建立的一个示例:using System;using System.Collections.Generic;... 阅读全文