While struggling to port a .net code to java, I've found this wonderful program named jni4net. The example codes worked fine for me, but it causes error in my dll.
My dll codes consists of Microsoft Office(powerpoint, word) interop assemblies. These two libraries seems to cause errors.
The auto generated code inside the build.cmd is :
csc /nologo /warn:0 /t:library /out:PrintDLL.j4n.dll /recurse:clr\*.cs /reference:"C:\Users\SJ\jni4net\bin\PrintDLL.dll" /reference:"C:\Users\SJ\jni4net\bin\jni4net.n-0.8.8.0.dll"
I tried to manually add the two libraries, by doing this
csc /nologo /warn:0 /t:library /out:PrintDLL.j4n.dll /recurse:clr\*.cs /reference:"C:\Users\SJ\jni4net\bin\PrintDLL.dll" /reference:"C:\Users\SJ\jni4net\bin\jni4net.n-0.8.8.0.dll" /reference:"C:\Windows\assembly\GAC_MSIL\Microsoft.Office.Interop.Word\15.0.0.0__71e9bce111e9429c\Microsoft.Office.Interop.Word.dll" /reference:"C:\Windows\assembly\GAC_MSIL\Microsoft.Office.Interop.PowerPoint\15.0.0.0__71e9bce111e9429c\Microsoft.Office.Interop.PowerPoint.dll"
Well, it didn't work, actually the modified code above resulted with thousands of new errors(though different from the original code).
Can anyone tell me how to mend this?