question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

could not load file or assembly 'System.Drawing.Common, Version=4.0.0.1, ...'

See original GitHub issue

Your Environment

  • ScottPlot Version: 4.0.48
  • Operating System: Windows 10 64bit, Visual Studio 2019
  • Is it a GUI app? What platform?
    • Platforms include WinForms, OpenCVsharp4

Describe the bug and how we can reproduce it. Hello, I see this error message, I have not had this error before. If I ignore this error, I don’t see any formsplots in winform designer neither add new forms plot. How can I solve this problem?

image

image

like following screenshot, there’s no error in build & debugging/execution. image

// a code sample may improve communication

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:12 (11 by maintainers)

github_iconTop GitHub Comments

2reactions
swhardencommented, May 2, 2021

Many thanks to @bukkideme for helping figuring this out over in #1004!

It seems this error is caused when System.Drawing.Common 5 is installed but downgraded to version 4. ScottPlot 4.1-beta is currently depending on version 5, but I’m going to change it to depend on version 4 so hopefully this issue will stop happening. Details are in https://github.com/ScottPlot/ScottPlot/issues/1004#issuecomment-830857864

This should do the trick:

  • Close Visual Studio
  • Delete the project’s bin and obj folders
  • Edit App.config to delete the bindingRedirect line
  • Open the project in Visual Studio and rebuild the solution
0reactions
bukkidemecommented, May 2, 2021

So I guess I should just install SDK 4.7.2.?? 😃

kép

Read more comments on GitHub >

github_iconTop Results From Across the Web

Could not load file or assembly 'System.ValueTuple'
I'm not understanding why it's not finding the file since it's in the same folder as my DLL. Apparently MS did not include...
Read more >
My script runs fine in VS2013 but not with CSScript - Can't ...
Background: I recently switched to VSCode (cause I've been doing some mobile hybrid development with ionic framework)
Read more >
Can't import PowerShell module that depends on NuGet ...
I have a C# PowerShell module coded for .NET 6.0. It depends on a C# library that started life in the same solution....
Read more >
Microsoft .NET Framework error upon emailing invoice ...
I've customized a template for my invoices. Upon emailing the invoice the following will happen, either: (a) the Print window as per usual ......
Read more >
Returning an NTSTATUS to an unmanaged caller from .NET
The operation completed successfully. Assembly manager loaded from: C:\Windows\Microsoft.NET\Framework64\v4.0.30319\clr.dll Running under executable F:\src\main ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found