【发布时间】:2011-06-05 00:06:05
【问题描述】:
我的“安全”程序集包含以下代码:
public delegate void InteropEventDelegate(InteropEventType etype, string data, string data2, string data3);
public event InteropEventDelegate InteropEvent;
第二个程序集引用了我的“安全”程序集,并包含以下代码:
void LoadSecurity()
{
if (!AssemblyIsLocked && Security == null)
{
this.Security = new Security.Security(UnlockCode);
this.Security.InteropEvent += new Security.Security.InteropEventDelegate(Security_InteropEvent);
}
}
void Security_InteropEvent(InteropEventType etype, string data, string data2, string data3)
{
throw new NotImplementedException();
}
Security_InteropEvent 由 IntelliSense 生成,并且具有正确的签名,但我收到错误消息“'Security_InteropEvent' 没有重载与委托 'Security.Security.InteropEventDelegate' 匹配”。为什么?
【问题讨论】:
标签: c# visual-studio-2010 .net-3.5