在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
[DllImport("OpenNetStream.dll")] public static extern int OpenSDK_Data_GetDevList(IntPtr szAccessToken, int iPageStart, int iPageSize, ref IntPtr pBuf, ref int iLength);
int size = 1024; byte[] managedArray = new byte[size]; Marshal.Copy(pBuf, managedArray, 0, size); 参考:http://stackoverflow.com/questions/5486938/c-sharp-how-to-get-byte-from-intptr https://msdn.microsoft.com/en-us/library/system.runtime.interopservices.marshal.copy.aspx |
请发表评论