61

I need to use/continue developing a desktop app developed using .NET on my Mac. Is there a .NET framework 4.0 available for Mac? Would this allow running and developing of .NET-based apps on a Mac?

Another option that i am considering is using a windows virtual machine on the Mac.

StayOnTarget
  • 11,743
  • 10
  • 52
  • 81
adz
  • 759
  • 1
  • 5
  • 9

5 Answers5

35

You can use a .Net environment Visual studio, Take a look at the differences with the PC version.

A lighter editor would be Visual Code

Alternatives :

  1. Installing the Mono Project runtime . It allows you to re-compile the code and run it on a Mac, but this requires various alterations to the codebase, as the fuller .Net Framework is not available. (Also, WPF applications aren't supported here either.)

  2. Virtual machine (VMWare Fusion perhaps)

  3. Update your codebase to .Net Core, (before choosing this option take a look at this migration process)

    • .Net Core 3.1 is an open-source, free and available on Window, MacOs and Linux

    • As of September 14, a release candidate 1 of .Net Core 5.0 has been deployed on Window, MacOs and Linux.

[1] : Release candidate (RC) : releases providing early access to complete features. These releases are supported for production use when they have a go-live license

mlaribi
  • 699
  • 1
  • 10
  • 18
28
  • .NET Core will install and run on macOS - and just about any other desktop OS.
    IDEs are available for the mac, including:

  • Mono is a good option that I've used in the past. But with Core 3.0 out now, I would go that route.

Pang
  • 9,564
  • 146
  • 81
  • 122
Sam Axe
  • 33,313
  • 9
  • 55
  • 89
  • 3
    If you reference .net framework libraries in your .net core console app will this work on Mac or no? – DorkMonstuh Apr 01 '18 at 11:26
  • 2
    The question is regarding .net framework, not .net core – emirhosseini Nov 20 '20 at 16:13
  • Running a .Net Core app with a form I get the msg “It was not possible to find any compatible framework version’, and provides a link to https://aka.ms.dotnet-core-applaunch?framework=Microsoft.WindowsDesktop.App&framework_version=3.1.0&arch=x64&rid=osx.10.15-x64 to install it. This link does not appear to exist – instead I am taken to https://dotnet.microsoft.com/download/dotnet-core/3/1/runtime//utm_source=getdotnetcore$utm_medium=referral. I have installed the .Net Core SDK (v 3.1.404) on the Mac but still get the same error. How can I fix the missing framework problem? – SimonKravis Dec 14 '20 at 11:23
9

Yes you can!

As of November 2016, Microsoft now has integrated .NET Core in it's official .NET Site

They even have a new Visual Studio app that runs on MacOS

Goldorak84
  • 3,714
  • 3
  • 38
  • 62
1

First you need to download the SDK and then you need to run this command. Because by default it does not add the env variable.

if you run this command in the terminal, it will fix your issue

ln -s /usr/local/share/dotnet/dotnet /usr/local/bin/
bizimunda
  • 819
  • 2
  • 9
  • 26
-1

.NetCore is a fine release from Microsoft and Visual Studio's latest version is also available for mac but there is still some limitation. Like for creating GUI based application on .net core you have to write code manually for everything. Like in older version of VS we just drag and drop the things and magic happens. But in VS latest version for mac every code has to be written manually. However you can make web application and console application easily on VS for mac.

  • 1
    I mean I don't want to be harsh on it, but it's in no way a "fine" release. The limitations really cause you to utilize both mac and pc versions to really optimally utilize. If you are are a hard core .net user, I don't see a way you could use mac only. – Randy May 29 '18 at 16:57
  • I can see lots of ways you would use mac only. Maybe you are making an app that would give redundant functionality on windows but fills a missing gap of functionality on mac. Happens all the time. – John Lord Jun 22 '23 at 18:48