MS Word中的WPF用户控件

编程入门 行业动态 更新时间:2024-10-22 09:50:57
本文介绍了MS Word中的WPF用户控件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

大家好, 我想知道如何用与ActiveX控件相同的方式将刚刚制作的WPF用户控件嵌入到MS Word文档中? 您认为这仍然可行吗? 提前非常感谢您. 最好的问候. MiQi.

Hello everyone, I would like to know how this could be possible to embed a wpf user control freshly made into a MS Word document in the same way we used to do with activex control ? Do you think this is still possible ? Thank you very much in advance. Best regards. MiQi.

推荐答案

通过ElementHost将WPF控件包装到Windows窗体的UserControl中,然后将此Windows窗体的控件公开为ActiveX控件,请参阅此有关如何操作的文章: 将Windows窗体控件公开为ActiveX控件 [ ^ ] Wrap the WPF control into a Windows Forms'' UserControl via ElementHost, then expose this Windows Forms''s Control as ActiveX control, please refer to this article on how to do it: Exposing Windows Forms Controls as ActiveX controls[^]

更多推荐

MS Word中的WPF用户控件

本文发布于:2023-11-08 07:10:15,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1568689.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:控件   用户   MS   Word   WPF

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!