namespace ikeyInterface
{
[Guid("F0356946-1F3E-49e9-9E9A-DE194A21DB39")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IObjectSafety
{
void GetInterfacceSafyOptions(
System.Int32 riid,
out System.Int32 pdwSupportedOptions,
out System.Int32 pdwEnabledOptions);
void SetInterfaceSafetyOptions(
System.Int32 riid,
System.Int32 dwOptionsSetMask,
System.Int32 dwEnabledOptions);
} public partial class iKeyActiveX : UserControl
{
ikeyActiveXClass c1 = new ikeyActiveXClass();
public iKeyActiveX()
{
InitializeComponent();
}
void GetInterfacceSafyOptions(System.Int32 riid, out System.Int32 pdwSupportedOptions, out System.Int32 pdwEnabledOptions)
{
pdwSupportedOptions = 1;
pdwEnabledOptions = 2;
}
void SetInterfaceSafetyOptions(System.Int32 riid, System.Int32 dwOptionsSetMask, System.Int32 dwEnabledOptions)
{
}
}
为什么每次生成的dll的guid都不一样
每次调试的时候得的去oleview 中查看一次它的guid
我都设置了guid了
不是一直都应该是设置的这一个么?
{
[Guid("F0356946-1F3E-49e9-9E9A-DE194A21DB39")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IObjectSafety
{
void GetInterfacceSafyOptions(
System.Int32 riid,
out System.Int32 pdwSupportedOptions,
out System.Int32 pdwEnabledOptions);
void SetInterfaceSafetyOptions(
System.Int32 riid,
System.Int32 dwOptionsSetMask,
System.Int32 dwEnabledOptions);
} public partial class iKeyActiveX : UserControl
{
ikeyActiveXClass c1 = new ikeyActiveXClass();
public iKeyActiveX()
{
InitializeComponent();
}
void GetInterfacceSafyOptions(System.Int32 riid, out System.Int32 pdwSupportedOptions, out System.Int32 pdwEnabledOptions)
{
pdwSupportedOptions = 1;
pdwEnabledOptions = 2;
}
void SetInterfaceSafetyOptions(System.Int32 riid, System.Int32 dwOptionsSetMask, System.Int32 dwEnabledOptions)
{
}
}
为什么每次生成的dll的guid都不一样
每次调试的时候得的去oleview 中查看一次它的guid
我都设置了guid了
不是一直都应该是设置的这一个么?
如果真的每次都改变的话
那不是太麻烦了
在每台机子上 那不都得改的不一样!
我每次点击运行 是一个新的activeX的guid
我只想更新旧的
要是guid更改了
在网页中的 <object id="ikeyInterface" classid="clsid:3378C25B-D62E-3964-868B-1AEA078E8F89" codebase ="step.exe" width="0" height="0">
这句话也得修改
我每次都要修改
[Guid("F0356946-1F3E-49e9-9E9A-DE194A21DB39")]
不是有这句话么?
这不就是分配这个guid个这activeX吗?
如果不是那这句话有啥用?
<object id="ikeyInterface" classid="clsid:3378C25B-D62E-3964-868B-1AEA078E8F89" codebase ="step.exe" width="0" height="0">
这么调用的
classid就是他的guid
所以需要它的值不要变!
和我这个情况差不多吧
http://topic.csdn.net/u/20100715/10/40eddbff-9e44-470f-8bee-1e4b59f98374.html
我是做一个activeX控件
我每次生成一次activeX的 guid就改变了
每次我都得去修改网页的 设置
我是guid已经改变了