ActiveX控件在IE以外的单独窗口中运行 [英] ActiveX Control is running in separate window other than IE

查看:129
本文介绍了ActiveX控件在IE以外的单独窗口中运行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在C#.NET中开发了ActiveX控件。我用默认接口创建了一个类库。给定GUID,ProgId并使其COM可见,可互操作。注册。创建一个cab文件,然后通过指定其classid和代码库,使用对象标签将其嵌入HTML页面。使用JavaScript方法加载了它。这是工作。但是问题在于它作为Internet Explorer以外的单独窗口运行。我希望将其作为IE窗口的一部分加载到IE中。

I have developed an ActiveX Control in C#.NET. I created a class library with a default interface. Given GUID , ProgId and made it COM visible , interoperable. Registered. Created a cab file , then embedded it in HTML page using object tag by specifying it's classid and codebase. Loaded it using JavaScript Method. It is working. But problem is that it runs as a separate window other than Internet explorer. I want it to be loaded inside IE that is as a part of IE window. How to do it?

-
谢谢。

推荐答案

可能,您在单独的 Form 中显示控件。您只需要从 UserControl 派生您的控件,注册它,然后让ActiveX容器(在您的情况下为IE)将您的控件嵌入到位。查看 C#ActiveX控件(CSActiveX)用于C#的互操作表单工具包

Probably, you show your control in a separate Form. You'd just need to derive your control from UserControl, register it and let the ActiveX container (IE in your case) embed your control in-place. Check out C# ActiveX control (CSActiveX) and Interop Forms Toolkit for C#.

这篇关于ActiveX控件在IE以外的单独窗口中运行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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