Page 1 of 1
A new WinForms App (.NET Framework 4.x) created from a scratch is not compiling
Posted: Tue Sep 19, 2023 2:49 pm
by 15685014
Hello.
I wanted to create a new application to demonstrate left axis strange behavior but I failed at the very beginning
I use latest Visual Studio Enterprise
2022 17.7.4 and latest Steema.TeeChart.NET
4.2023.8.31 nuget package.
For WinForms App targeting .NET Framework
4.0 it is no even compiling (
TeeChart WPF and
TeeChart tabs are added to a toolbox and I drop
TChart control from a
TeeChart tab to my form):
For WinForms App targeting .NET Framework
4.8 it fails in runtime (
TeeChart.WinForm,
TeeChart.WPF and
TeeChart tabs are added to a toolbox and I have to drop
TChart control from a
TeeChart.WinForm tab to my form because
TeeChart tab lacks that control):
Same situation appears in latest Visual Studio Enterprise
2019 16.11.30 but in that IDE
TeeChart* tab on a toolbox is not even created. But if I add new TChart to a form via code - same errors occurs (respecting target .NET Framework version).
What is my mistake?
Re: A new WinForms App (.NET Framework 4.x) created from a scratch is not compiling
Posted: Tue Sep 19, 2023 5:34 pm
by Marc
Hello,
This is unexpected behaviour. We'll run a check to confirm.
Regards,
Marc Meumann
Re: A new WinForms App (.NET Framework 4.x) created from a scratch is not compiling
Posted: Tue Sep 19, 2023 6:13 pm
by Marc
Hello,
We've checked, here's the workaround that tested ok here re-tracing your steps.
After adding TeeChart via Nuget, look for Microsoft's "System.Text.Json" in the Nuget Manager and install it. The latest version is v7.03. The version number is a misnomer, it doesn't depend on the later framework, you'll see a dependency for Framework 4.6+.
Rebuild all and the project should run ok. We'll check what we can do to improve required steps here.
Regards,
Marc
Re: A new WinForms App (.NET Framework 4.x) created from a scratch is not compiling
Posted: Wed Sep 20, 2023 5:11 am
by 15685014
Marc wrote: ↑Tue Sep 19, 2023 6:13 pm
After adding TeeChart via Nuget, look for Microsoft's "System.Text.Json" in the Nuget Manager and install it. The latest version is v7.03.
So when targeting .NET Framework
4.8:
- workaround solves the problem in VS 2022 17.7.4
- workaround doesn't NOT solve the problem in VS 2019 16.11.30:
To sum up current problems are:
- VS 2022 and NFW 4.8 - not working out of the box, adding latest System.Text.Json nuget solves the problem.
- VS 2022 and NFW 4.0 - not working out of the box (license.licx problem), no workaround for now.
- VS 2019 and NFW 4.8 - not working out of the box, adding latest System.Text.Json nuget DOESN'T solve the problem.
- VS 2019 and NFW 4.0 - not working out of the box (license.licx problem), no workaround for now.
- In VS 2022 for NFW 4.8 TeeChart.WinForm, TeeChart.WPF, TeeChart tabs are added (TChart control is on TeeChart.WinForm tab):
while for NFW 4.0 TeeChart WPF and TeeChart tabs are added to a toolbox (TChart control is on TeeChart tab):
Is that by design or a bug?
- In VS 2019 both for NFW 4.8 and NFW 4.0 TeeChart* tabs are NOT added to a toolbox. Is that a bug?
Re: A new WinForms App (.NET Framework 4.x) created from a scratch is not compiling
Posted: Mon Sep 25, 2023 5:19 am
by 15685014
Hmm, 5 days have passed (a full 3 business days) - still no reaction. Very disappointing..
Re: A new WinForms App (.NET Framework 4.x) created from a scratch is not compiling
Posted: Mon Sep 25, 2023 7:34 am
by ruben
Good morning,
I apologize for the delay. Thank you for providing us with all this information.
We are working on resolving the issue for avoid manually have to add the "System.Text.Json" dependency. In VS2019 and VS2022, adding the dependency to your project should fix it. If the error persists, please try cleaning the "bin" / "obj" folders or cleaning the solution.
The NFW4.0 version is deprecated, so it's likely that many things won't work. Currently, the minimum version is NFW4.8. We are aware that in some versions, the "toolbox" may appear differently, and we will try to address this.
Thanks,
Ruben
Re: A new WinForms App (.NET Framework 4.x) created from a scratch is not compiling
Posted: Mon Sep 25, 2023 9:46 am
by 15685014
Rubén wrote: ↑Mon Sep 25, 2023 7:34 am
The NFW4.0 version is deprecated, so it's likely that many things won't work. Currently, the minimum version is NFW4.8.
Latest
Steema.TeeChart.NET 4.2023.8.31 nuget
targets .NET Framework 4.0 among others. Targeting means that package is stably working and supported on that TFM, isn't it? Support cannot result in situation when "many things won't work".
P. S. If despite of that NFW 4.0 support was actually dropped - what is the latest package version that supports it?
Re: A new WinForms App (.NET Framework 4.x) created from a scratch is not compiling
Posted: Mon Sep 25, 2023 12:49 pm
by ruben
bairog wrote: ↑Mon Sep 25, 2023 9:46 am
If despite of that NFW 4.0 support was actually dropped - what is the latest package version that supports it?
The latest version that supports .NET 4.0 is "4.2023.4.18", should work fine in that version.
bairog wrote: ↑Mon Sep 25, 2023 9:46 am
Targeting means that package is stably working and supported on that TFM, isn't it
We need to increase the minimum required version for the package. Thank you.
Re: A new WinForms App (.NET Framework 4.x) created from a scratch is not compiling
Posted: Mon Sep 25, 2023 1:09 pm
by 15685014
Rubén wrote: ↑Mon Sep 25, 2023 12:49 pm
The latest version that supports .NET 4.0 is "4.2023.4.18", should work fine in that version.
What do you mean? As you can see from my
previous post new application for NFW 4.0 is not compiling both in VS 2022 and VS 2019.
Rubén wrote: ↑Mon Sep 25, 2023 12:49 pm
We need to increase the minimum required version for the package. Thank you.
Yes, but first you need to provide a workaround how to fix compile error on NFW 4.0 if you suppose
4.2023.4.18 stable on that platform.
Re: A new WinForms App (.NET Framework 4.x) created from a scratch is not compiling
Posted: Mon Sep 25, 2023 3:28 pm
by Marc
Hello,
We're checking the options here. Our test results for VSNet2019:
- If you wish to use Framework 4.0, we confirm that TeeChart v4.2023.4.18 works correctly on Winform for both a designtime and runtime chart.
- If you are able to use Framework 4.5.1, we confirm that TeeChart v4.2023.8.31, the latest version, works correctly on Winform for both a designtime and runtime chart.
- If you wish to use Framework 4.8 and TeeChart v4.2023.8.31, we confirm that:
- a manual dependency for System.text.json is required
- It will work correctly on Winform for a runtime but not at designtime chart.
- This last area, 4,8 and latest build of TeeChart, is where we are working to provide a transparent solution.
What version do you wish to use?
Re:
VS 2022 and NFW 4.0 - not working out of the box (license.licx problem), no workaround for now.
Remove any TeeChart text lines from the licx file.
With thanks.
Regards,
Marc
Re: A new WinForms App (.NET Framework 4.x) created from a scratch is not compiling
Posted: Tue Sep 26, 2023 4:52 am
by 15685014
Marc wrote: ↑Mon Sep 25, 2023 3:28 pm
If you wish to use Framework 4.0, we confirm that TeeChart v4.2023.4.18 works correctly on Winform for both a designtime and runtime chart.
I confirm that versions up to and including
v4.2023.8.3 work correctly (out-of-the box, no extra steps are necessary) on
.NFW 4.0 for both a designtime and runtime chart (both VS 2019 and 2022):
We will use that version in our deep legacy projects (where .NFW 4.0 is the only option).
Marc wrote: ↑Mon Sep 25, 2023 3:28 pm
- If you wish to use Framework 4.8 and TeeChart v4.2023.8.31, we confirm that:
- a manual dependency for System.text.json is required
- It will work correctly on Winform for a runtime but not at designtime chart.
- This last area, 4,8 and latest build of TeeChart, is where we are working to provide a transparent solution.
It is clear that you will fix for .NFW 4.8 only (I suppose you will also drop .NFW 4.0 target in next versions to avoid misleading developers).
Marc wrote: ↑Mon Sep 25, 2023 3:28 pm
Re:
VS 2022 and NFW 4.0 - not working out of the box (license.licx problem), no workaround for now.
Remove any TeeChart text lines from the licx file.
As I investigated above VS 2022 and NFW 4.0 works correctly with
v4.2023.8.3 (out-of-the box, no extra steps are necessary).