- ago
The DrawBarAnnotation(...) function creates the following version conflict between System.Drawing.Common and System.Runtime. Why is this a problem and how do I correct it?
1
884
Solved
7 Replies

Reply

Bookmark

Sort
Glitch8
 ( 8.08% )
- ago
#1
It’s not correctable, very sorry for the inconvenience. It’s just an issue in the editor though, it should not effect running your strategy.
1
Best Answer
- ago
#2
I'm "guessing" this will go away once we move to .NET 6.0.

I think this transitional period as software moves from .NET 4.6/4.7 to Core 3.0/3.1 to .NET 5 to .NET 6.0 is very confusing. Thanks for your help.
0
edwkelly8
 ( 0.06% )
- ago
#3
bool isBullish = bars.Close[idx] > bars.Open[idx];
string annotation = isBullish ? "Bullish" : "bearish";
Color c = isBullish ? Color.Green : Color.Red;
DrawBarAnnotation(annotation, idx, isBullish, c, 6);

Above runs ok in WL7 build 51 C# code editor but I am unable to get it working in VS2019 running a class library project with .net core 3.1 framework. I've never used a core framework but VS requires me to install System.Drawing.Common V4.0 from Nuget to get DrawBarAnnotation routine to build. But, Nuget only has V4.5 at the earliest. Then running it VS degugger just skips the overide Execute completely. Installing a non core framework also fails. Please advise.
0
- ago
#4
Here's the solution for Visual Studio:

https://www.wealth-lab.com/Discussion/Error-adding-System-Drawing-Common-package-to-custom-extension-6351

If you have further questions let's reuse that topic.
0
edwkelly8
 ( 0.06% )
- ago
#5
Will do.
0
- ago
#6
This issue will probably disappear after we switch (from WL7 and Core 3.1) to WL8 and .NET 6.0. I think the compatibility problem stems from using Core 3.1 instead of .NET 6.0, so it's a transitional GUI framework problem.
0
edwkelly8
 ( 0.06% )
- ago
#7
Agree, thanks for your input.
0

Reply

Bookmark

Sort