问题描述
本人非IT专业,但热衷于用编程来简化工作流程,我有一个问题,想像各位高手请教,就是程序中引用第三方软件(EPLAN)的API,总是说找不到,然后查找到它的帮助文档,如下:Youcanmakesure,theAPIassembliesareloadedfromthebindirectorybydifferentmeans:Thisistheeasiestway:YoucanjustcopytheexecutableofyourofflineapplicationtotherespectivebinfolderoftheEPLANversion,whichyouwanttouse.Thesecondway,istopublishthecodebasesofallneededAPIassembliesintheapplicationconfigfile.(AnXMLfile,whichisnamedlikeyourexecutablewithanadditionalextension.config.,e.g.MyApplication.exe.config).Thefollowingcodeshowsanexampleforthecontentsofsuchaconfigfile.<?xmlversion="1.0"encoding="utf-8"?><configuration><runtime><assemblyBindingxmlns="urn:schemas-microsoft-com:asm.v1"><dependentAssembly><assemblyIdentityname="Eplan.EplApi.Systemu"publicKeyToken="57aaa27e22f7b107"/><publisherPolicyapply="yes"/><codeBaseversion="1.0.0.0"href="file:////C:/programfiles/EPLAN/ElectricP8/x.x.x/BIN/Eplan.EplApi.Systemu.dll"/></dependentAssembly><dependentAssembly><assemblyIdentityname="Eplan.EplApi.AFu"publicKeyToken="57aaa27e22f7b107"/><publisherPolicyapply="yes"/><codeBaseversion="1.0.0.0"href="file:////C:/programfiles/ElectricP8/x.x.x/BIN/Eplan.EplApi.Afu.dll"/></dependentAssembly><dependentAssembly><assemblyIdentityname="Eplan.EplApi.Baseu"publicKeyToken="57aaa27e22f7b107"/><publisherPolicyapply="yes"/><codeBaseversion="1.0.0.0"href="file:////C:/programfiles/EPLAN/ElectricP8/x.x.x/BIN/Eplan.EplApi.Baseu.dll"/></dependentAssembly><dependentAssembly><assemblyIdentityname="Eplan.EplApi.DataModelu"publicKeyToken="57aaa27e22f7b107"/><publisherPolicyapply="yes"/><codeBaseversion="1.0.0.0"href="file:////C:/programfiles//EPLAN/ElectricP8/x.x.x/BIN/Eplan.EplApi.DataModelu.dll"/></dependentAssembly><dependentAssembly><assemblyIdentityname="Eplan.EplApi.HEServicesu"publicKeyToken="57aaa27e22f7b107"/><publisherPolicyapply="yes"/><codeBaseversion="1.0.0.0"href="file:////C:/programfiles/EPLAN/ElectricP8/x.x.x/BIN/Eplan.EplApi.HEServicesu.dll"/></dependentAssembly><dependentAssembly><assemblyIdentityname="Eplan.EplApi.GUIu"publicKeyToken="57aaa27e22f7b107"/><publisherPolicyapply="yes"/><codeBaseversion="1.0.0.0"href="file:////C:/programfiles/EPLAN/ElectricP8/x.x.x/BIN/Eplan.EplApi.GUIu.dll"/></dependentAssembly></assemblyBinding></runtime></configuration>其中第一种方法,我已经测试成功,但感觉需要把可执行文件和EPlan的DLL放在一起,不好,并希望使用第二种方法,其中那个XML配置文件已经创建好了,但不知如何对其进行处理,请能教导一下,在此非常感谢!
解决方案
解决方案二:
怎么没人帮助啊?