c#中如何转换VB语法“Byref",请高手来,高分等!在线等!
Public Declare Function bAutoInit Lib "Com.dll" (ByRef CommInfo As STRUCommInfo) As Boolean
如上VB的API:
在C#中
我翻译成:
[ DllImport( "Com.dll", EntryPoint="bAutoInit")]
public static extern bool bAutoInit(ref STRUCommInfo CommInfo) ;
调用时:
bRet = bAutoInit(ref com_inf);
却总是报“System.ExecutionEngineExcept”异常,
请高手指教,急急急哦