Support for .NET6

I have recently attempted to convert all of our software from .NET Framework v4.8 to 6.0. Whilst everything builds and runs, attempting to show a form containing the syntax editor results in the following exception:

BinaryFormatter serialization is obsolete and should not be used. See BinaryFormatter security guide | Microsoft Docs for more information

Here is the stack trace (apologies for the image, hard to get text out of this environment):

Any chance this is slated to be fixed in the next release which is due out early next year?

Hi,

this is very interesting for me, too.
We also want to upgrade to .net 6.
I get following error message when I start our application:
Method ‘get_ContextMenu’ in type ‘Alternet.Editor.SyntaxEdit’ from assembly ‘Alternet.Editor.v6, Version=6.2.0.0, Culture=neutral, PublicKeyToken=8032721e70924a63’ does not have an implementation.

Any advice would be helpful.

Karol

After upgrading to Alternet Studio 7.2 I have exactly the same problem.

Best Regards
Karol

Hi Andrew,

I wonder if you used assemblies from C:\Program Files (x86)\AlterNET Software\AlterNET Studio v.7\Bin\ folder in .NET 6 application? These libraries are built for 4.6.1 .NET Framework, so they might cause issue with licensing if used in .NET Core/.NET 6 applications (as licx mechanism seems to be obsolete in .NET Core)

I would suggest to use our multi-target packages instead - please refer to the complete list of these package here:

https://www.nuget.org/profiles/Alternet

As an example, Alternet.Studio.Editor.WindowsForms package contains Code Editor WinForms libraries build for .net 5, which .net 6 application will use instead of ones built for 4.6.1 Framework.
Let me know if this works for you.

These packages will support .NET 6 target in the coming update (version 8).

Karol, we’ve seen issue with get_ContextMenu only in situation when assemblies from different version were mixed (say if AlterNET.Editor.v7.dll was of version 7.2, but Alternet.Common.v7.dll was of version 7.0). If you could upload your cut-down version of your project where this issue can be reproduced (with Bin folder), we will be able to have a closer look at it.

Kind regards,
Dmitry

Dmitry,

I have added every package that is available in nuget, and I simply cannot find the TypeScriptTokenizer class. This is in Alternet.Syntax.Parsers.TypeScript.v7.dll in the 4.6.1 framework side of things. Can you please tell me where to find it in the .NET 5 version? I thought for sure it would be under Alternet.Syntax.Parsers.TypeScript but there is no such namespace - I can only choose from ‘Generic’ or ‘Advanced’.

Thanks

Andrew

Hi Andrew,

.NET Core target is not currently supported by TypeScript. We did some research and hit few roadblocks when trying to support .NET core. We will look at at again to see if it’s feasible to push this feature to the coming release.

Regards,
Dmitry

1 Like

Thank you Dmitry,

using the nuget packages fixed my problem.
Regarding my first problem: I’m not sure if I will be able to provide a simple reproduce…

Best Regards
Karol

Hi Karol,

Just to clarify, when you use NuGet packages, you no longer get issue with get_ContextMenu?
As I mentioned before it’s likely that it would happen if you mix assemblies from different minor versions.

Regards,
Dmitry

Hi Dmitry,

Happy New Year!

I confirm that I do not have the above issue anymore when using NuGet packages.

Best Regards
Karol

Hi Karol,

Thank you for confirming.

Happy New Year to you too!

Regards,
Dmitry