xxxxxxxxxx
C:\tools\dart-sdk // which is installed in this location as default
xxxxxxxxxx
On macos: After installing dart using brew install dart, run brew info dart
At the bottom it prints:
Please note the path to the Dart SDK:
/usr/local/opt/dart/libexec
xxxxxxxxxx
I had the same problem after importing a flutter project from git. These are
the steps to solve the problem.
1. Inside Android Studio File->Settings->Language & Framework->Flutter
2. Choose flutter SDK path: the first time we install flutter, we choose the
location where the flutter should be installed. Choose this location.
3. Click OK and the android studio will refresh. Carry on if the problem is
solved.
4. If you are still stuck with the error.
5. Goto this link and install Dart. (https://flutter.io/get-started/install/)
6. Goto the same place in settings, ..Language & Framework->Dart and chose the
SDK location. This solved the issues for me.
xxxxxxxxxx
1. Open Android Studio.
2. Go to File > Settings.
3. In the left-hand side menu, select Languages & Frameworks > Flutter.
4. Click on the ellipsis ( ) icon next to Dart SDK path.
5. Browse and select the folder where your Dart SDK is located.
6. Save the changes by clicking on OK.