I read many questions on running .net code with mono but i always end up with the same question. I'm building a new app right now, so i better start straight and take the good direction:
Can i develop an app within Visual C# Express or Visual Basic Express, compile it from the Microsoft environment using the compilers they have and run that application using MONO on linux.
Or do i have to work with the mono compiler from scratch (or convert my MS project afterwards to mono) to be able to use my .net apps using the Mono framework on linux.
Linux/Mac support is not really a must for my app development, but i'd like to get it straight off the start.
Thanks
Regarding the apis:
i'm using WinForms, Encryption, Globalization, SQLClient but thats probably all, is there anything you Mono experts out can tell me NOT to use off the start.
Oh and i use the My namespace for all sorts of things such as getting the computer name, logged on user name, resources, settings, etc...
Yes, Mono can run applications developed with the Microsoft . NET Framework on UNIX.
NET Core, which natively only allows you to build console apps and web applications, mono allows you to build many application types available in . NET Framework, including GUI-enabled desktop apps. So, if mono can do everything that . NET Core can while .
NET 5 launches in November 2020, it will produce two runtimes: CoreCLR and mono. CoreCLR will extend . NET Core 3 to encompass the features of . NET Framework and mono; mono will continue to exist so developers can choose to target either it or CoreCLR.
Generally yes, that works.
The issue isn't recompiling, it's the available native APIs and libraries. If you add native interop, the library you work with must be available on Linux too, which obviously isn't the case for the windows libraries.
Certain managed libraries aren't available at all(WPF), or are incomplete (WCF).
Mono has a WinForms implementation, but it looks foreign, since it doesn't use native controls. This means the code will work on other platforms, but the user experience won't be nice.
All compilers for .Net languages compile to standard MSIL, which can be executed by any compliant implementation, including Mono.
However, some assemblies included with Microsoft.Net and Visual Studio are not available for Mono on non-Windows platforms.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With