0

I encountered this error:

************** Exception Text ************** System.IO.FileNotFoundException: Could not load file or assembly 'Google.Apis.Core, Version=1.58.0.0, Culture=neutral, PublicKeyToken=4b01fa6e34db77ab' or one of its dependencies. The system cannot find the file specified. File name: 'Google.Apis.Core, Version=1.58.0.0, Culture=neutral, PublicKeyToken=4b01fa6e34db77ab'
at DataManager.Form2.Form2_Load(Object sender, EventArgs e) at System.Windows.Forms.Form.OnLoad(EventArgs e) at System.Windows.Forms.Form.OnCreateControl() at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
at System.Windows.Forms.Control.CreateControl() at System.Windows.Forms.Control.WmShowWindow(Message& m) at System.Windows.Forms.Control.WndProc(Message& m) at System.Windows.Forms.Form.WmShowWindow(Message& m) at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

WRN: Assembly binding logging is turned OFF. To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1. Note: There is some performance penalty associated with assembly bind failure logging. To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].

This exception happens only when I build the application an install it with Setup wizard. Then I get another error like this but with the "Google.Apis.Auth". I don't know if it can cause this error but I load the program on multiple threads. Because of this, sometimes the SQlite does not have time to open the connection with the db. So I don't know if it just can't load these dlls.

And I also have some warnings like this:

Warning The explicit binding redirect on "Google.Apis.Core, Culture=neutral, PublicKeyToken=4b01fa6e34db77ab" conflicts with an autogenerated binding redirect. Consider removing it from the application configuration file or disabling autogenerated binding redirects. The build will replace it with: "". DataManager

I hope if someone could help me avoiding this error in the future. Let me know If you need additional information! Thanks!

update: I tried turning off "Auto-generate binding redirects" but it's still not working properly!

1 Answers1

1

Okay now I managed to make it work by deleting the highlighted references from Project>references (Auto-generate binding redirects is still off)

I rebuilt the project with the deleted references now it looks okay now.

I still welcome answers that can describe what caused and how can I avoid these kind of problems in the future!