Mono problem!

Ramon00

New Member
Joined
Jul 29, 2021
Messages
22
Reaction score
0
Credits
202
Hello folks, i'm getting this error when i use mono to run a windows form in a raspberry pi 4:

mono WindowsFormsApp1.exe

Unhandled Exception:
System.NotImplementedException: The method or operation is not implemented.
at System.Windows.Forms.DataVisualization.Charting.Chart.BeginInit () [0x00000] in <61b54473af0749979111adb4b4594d72>:0
at WindowsFormsApp1.Form1.InitializeComponent () [0x000ea] in <1d0a7fae1d1146189e6b64ff793bd831>:0
at WindowsFormsApp1.Form1..ctor () [0x0000f] in <1d0a7fae1d1146189e6b64ff793bd831>:0
at (wrapper remoting-invoke-with-check) WindowsFormsApp1.Form1..ctor()
at WindowsFormsApp1.Program.Main () [0x0000e] in <1d0a7fae1d1146189e6b64ff793bd831>:0
[ERROR] FATAL UNHANDLED EXCEPTION: System.NotImplementedException: The method or operation is not implemented.
at System.Windows.Forms.DataVisualization.Charting.Chart.BeginInit () [0x00000] in <61b54473af0749979111adb4b4594d72>:0
at WindowsFormsApp1.Form1.InitializeComponent () [0x000ea] in <1d0a7fae1d1146189e6b64ff793bd831>:0
at WindowsFormsApp1.Form1..ctor () [0x0000f] in <1d0a7fae1d1146189e6b64ff793bd831>:0
at (wrapper remoting-invoke-with-check) WindowsFormsApp1.Form1..ctor()
at WindowsFormsApp1.Program.Main () [0x0000e] in <1d0a7fae1d1146189e6b64ff793bd831>:0

Can you help me?
 


I'm no programmer but this error stands out.
System.NotImplementedException: The method or operation is not implemented.
Seems whatever you are trying to run in mono is not implemented in mono so you can't run it and are getting a "Fatal Error Unhandled Exception".
 
I'm no programmer but this error stands out.

Seems whatever you are trying to run in mono is not implemented in mono so you can't run it and are getting a "Fatal Error Unhandled Exception".
Yes, that appears as if there is a required library that isn't installed.
 
AFAIK Windows forms are not available in Mono. They’ve never been available and probably never will be.

If you’re using Windows forms, you’ll have to stick with running your application on Windows.

Or perhaps port the winforms part of your project to something like GTK# (C#/mono bindings for GTK).

Otherwise, rewrite/reimplement your application using something which is more cross-platform - like QT with C++, or perhaps QT with Python?!

That way, your application will compile and run on Windows and Linux with the same codebase. No need for separate ports.

Mono is great for cross-platform command line applications, but not so great for cross platform GUI applications.

It is possible to create cross platform GUI applications in C#/Mono - using libraries like GTK# - but GTK# is probably a ball ache to set up in windows with visual studio.

I’d imagine to get your application to work properly on windows and Linux - you’d have to ditch winforms and use mono/GTK# on Windows and Linux. Not sure offhand whether monodevelop is available for windows. I haven’t done anything with C#, or mono in many years. So I don’t know the current state of play. Doesn’t seem like it’s changed much though.

Personally, if the aim here is to create something that is cross platform, I’d ditch C# for something more portable like C++, Python, Go, or virtually anything else!
 

Staff online

Members online


Top