0
對於我的英語不好,我很抱歉,我是意大利人。 我有一個問題。我正在爲Microsoft Access報告工作.Net ActiveX控件。該控件是使用COM接口作爲合同和Interop Services(如屬性)構建的。該控制是由Access檢索和工作正常,現在我需要在設計模式下的「ControlSource」,用於數據源列選擇訪問的屬性。使用.Net框架編寫的Microsoft Access Report ActiveX控件
屬性「控件」我試圖在接口契約來實現是這樣的:
[DispId(0x1b)]
string ControlSource {
[return: MarshalAs(UnmanagedType.BStr)]
[MethodImpl(
MethodImplOptions.InternalCall,
MethodCodeType = MethodCodeType.Runtime), DispId(0x1b)] get;
[param: In, MarshalAs(UnmanagedType.BStr)]
[MethodImpl(
MethodImplOptions.InternalCall,
MethodCodeType = MethodCodeType.Runtime), DispId(0x1b)] set;
}
但它仍然無法正常工作。任何想法? 預先感謝任何想幫助我的人。