相关疑难解决方法(0)

是否有工具为任意非托管DLL生成P/Invoke签名?

我偶然发现了一个为Microsoft自己的非托管DLL生成P/Invoke签名的工具:PInvoke Interop Assistant

是否有类似的工具将为第三方非托管DLL生成P/Invoke签名?

或者,任何方式将第三方DLL提供给PInvoke Interop Assistant

编辑:我试图解决的实际问题

.net c# pinvoke unmanaged function-signature

34
推荐指数
4
解决办法
2万
查看次数

从C#调用C DLL

我试图从C#调用一个C DLL,但我没有任何快乐.DLL的文档提供了VB的示例函数delaration,看起来像;

Declare Function TransGeogPt Lib "c:\DLLS\GDAit.dll" (ByVal sGridFile As String, ByVal lDirection As
Long, ByVal dLat As Double, ByVal dLong As Double, pdLatNew As Double, pdLongNew As Double,
pdLatAcc As Double, pdLongAcc As Double) As Long

Declare Function TransProjPt Lib "c:\DLLS\GDAit.dll" (ByVal sGridFile As String, ByVal lDirection As
Long, ByVal dLat As Double, ByVal dLong As Double, ByVal lZone As Long, pdLatNew As Double,
pdLongNew As Double, pdLatAcc As Double, pdLongAcc As Double) As Long
Run Code Online (Sandbox Code Playgroud)

因此我做了以下事情;

public class GDAIt …
Run Code Online (Sandbox Code Playgroud)

c c# dll pinvoke dllimport

9
推荐指数
1
解决办法
3万
查看次数

标签 统计

c# ×2

pinvoke ×2

.net ×1

c ×1

dll ×1

dllimport ×1

function-signature ×1

unmanaged ×1