111,120
社区成员
发帖
与我相关
我的任务
分享<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity Name="Library" Culture="neutral" PublicKeyToken="null" />
<codeBase version="1.0.0.0" href="FILE://D:/my/Library.dll"/>
</dependentAssembly>
</assemblyBinding>
</runtime>
</configuration>
即使给Library产生一个PublicKeyToken,并在配置文件中指明,也是没用的
//试试下面的
//路径也可以写在INI文件或者XML文件中
[System.Runtime.InteropServices.DllImport("读取配置文件中的路径", EntryPoint = "方法", CharSet = System.Runtime.InteropServices.CharSet.Auto, SetLastError = false)]
static extern int 方法();