Could not load custom DLL

Questions about Wine on Linux
Locked
ravijoshi
Level 1
Level 1
Posts: 6
Joined: Sat Sep 21, 2019 4:47 am

Could not load custom DLL

Post by ravijoshi »

Hi,
I am new to wine. I am using wine 4.0 on Ubuntu 14.04 LTS 64 bit OS. I am trying to execute a .NET application which uses many DLLs such as OpenTK.dll, ZedGraph.dll, etc. Furthermore, my application also uses custom DLL made by myself. Please note that the application works fine on Windows OS.

While executing the application on wine, it throws the following error-

Code: Select all

System.InvalidOperationException: There is an error in XML document (2. 2). --->
System.TypeLoadException: Could not load type of field
'MyModel.MyClass:MyMethod' (11) due to: Could not load file or
assembly 'mydll, Version=0.0.0.0. Culture=neutral, PublicKeyToken=null' or one of its
dependencies. assembly.mydll Version=0.0.0.0. Culture=neutral,
PublicKeyToken=null type:<unknown type> member<none>
Please note that all DLLs are kept inside a subfolder. I highly suspect that I need to set the PATH accordingly.

Any suggestions, please.

-
Thanks
Ravi
User avatar
DarkShadow44
Level 8
Level 8
Posts: 1207
Joined: Tue Nov 22, 2016 5:39 pm

Re: Could not load custom DLL

Post by DarkShadow44 »

I doubt PATH is the issue. There could be a problem with sxs, or something else. Can you provide a full terminal output?
ravijoshi
Level 1
Level 1
Posts: 6
Joined: Sat Sep 21, 2019 4:47 am

Re: Could not load custom DLL

Post by ravijoshi »

Hi @DarkShadow44,

Thanks for the quick response. Please follow the URL below to see the erros reported at the terminal-
https://pastebin.com/D0TrLpGY

Here is the screenshot of the error popped up in the dialogue-
https://www.dropbox.com/s/i8l77muakln7x ... r.png?dl=0

The application opens but doesn't show up properly.

-
Thanks
Ravi
User avatar
DarkShadow44
Level 8
Level 8
Posts: 1207
Joined: Tue Nov 22, 2016 5:39 pm

Re: Could not load custom DLL

Post by DarkShadow44 »

I see you're using wine-mono, did you already try native .NET?
ravijoshi
Level 1
Level 1
Posts: 6
Joined: Sat Sep 21, 2019 4:47 am

Re: Could not load custom DLL

Post by ravijoshi »

DarkShadow44 wrote: Sun Sep 22, 2019 6:53 am did you already try native .NET?
What's that? I am sorry I haven't run .NET applications in Linux before. Can you please elaborate a bit more?
User avatar
DarkShadow44
Level 8
Level 8
Posts: 1207
Joined: Tue Nov 22, 2016 5:39 pm

Re: Could not load custom DLL

Post by DarkShadow44 »

I mean, use winetricks to install native .NET:

Code: Select all

winetricks -q dotnet472
ravijoshi
Level 1
Level 1
Posts: 6
Joined: Sat Sep 21, 2019 4:47 am

Re: Could not load custom DLL

Post by ravijoshi »

Thanks, @DarkShadow44.

I installed dotnet45. The application opens up but shows a dialogue saying that unhandled exception has occurred in your application. Please see the screenshot below-
https://www.dropbox.com/s/xfsbqkdswkegm60/null%20pointer%20error.png?dl=0

There is no specific error reported at the terminal. However, I found a few interesting candidates. Please see below-

Code: Select all

0009:fixme:shell:URL_ParseUrl failed to parse L"System.Windows.Forms"
0009:fixme:shell:URL_ParseUrl failed to parse L"System"
0009:fixme:shell:URL_ParseUrl failed to parse L"System.Drawing"
0009:fixme:olepicture:OLEPictureImpl_QueryInterface () : asking for unsupported interface {00000144-0000-0000-c000-000000000046}
0009:fixme:olepicture:OLEPictureImpl_QueryInterface () : asking for unsupported interface {b196b283-bab4-101a-b69c-00aa00341d07}
0009:fixme:olepicture:OLEPictureImpl_QueryInterface () : asking for unsupported interface {00000144-0000-0000-c000-000000000046}
0009:fixme:gdiplus:GdipGetFamilyName No support for handling of multiple languages!
0009:fixme:gdiplus:GdipGetLineSpacing ignoring style
0009:fixme:gdiplus:GdipGetLineSpacing ignoring style
0009:fixme:gdiplus:GdipGetLineSpacing ignoring style
0009:fixme:gdiplus:GdipGetNearestColor (0x49f5c68, 0x33d0bc): Passing color unmodified
0009:fixme:gdiplus:GdipGetNearestColor (0x49f5c68, 0x33d0bc): Passing color unmodified
0009:fixme:gdiplus:GdipGetNearestColor (0x49f5c68, 0x33d0bc): Passing color unmodified
0019:fixme:service:QueryServiceConfig2W Level 6 not implemented
0019:fixme:service:QueryServiceConfig2W Level 6 not implemented
0019:fixme:service:QueryServiceConfig2W Level 6 not implemented
-
Regards
Ravi
User avatar
DarkShadow44
Level 8
Level 8
Posts: 1207
Joined: Tue Nov 22, 2016 5:39 pm

Re: Could not load custom DLL

Post by DarkShadow44 »

Please don't cut logs. Just let it crash, and post the full terminal output.
ravijoshi
Level 1
Level 1
Posts: 6
Joined: Sat Sep 21, 2019 4:47 am

Re: Could not load custom DLL

Post by ravijoshi »

Dear @DarkShadow44,

I apologize for the inconvenience.

Below is the screenshot of the dialogue popped up during startup-
https://www.dropbox.com/s/wrtabr2ttra60gb/Startup%20Error.png?dl=0

You can see that the details contain a lot of text. I was able to copy it in a text file. Please see below the link to the text inside the popup dialoge box-
https://pastebin.com/s9Bfcckv

I have also copied the complete output reported at the terminal. Below is the link-
https://pastebin.com/ikQgPUqj

Please have a look. Thank you very much.

-
Ravi
User avatar
DarkShadow44
Level 8
Level 8
Posts: 1207
Joined: Tue Nov 22, 2016 5:39 pm

Re: Could not load custom DLL

Post by DarkShadow44 »

Hum, there's not much to work with. It would be good to know where exactly in " RAUserInterface.DHParamForm.PopulateDOFList" the null pointer exception happens, but you need the program for that.
In any case, I think a bug report would be warranted.
ravijoshi
Level 1
Level 1
Posts: 6
Joined: Sat Sep 21, 2019 4:47 am

Re: Could not load custom DLL

Post by ravijoshi »

I understand. Thank you very much!
Locked