4

I have created a flutter project on VS, and could not run any command through VS code's terminal, I have reinstalled the VS code and still give me this error:

[X] Visual Studio - develop for Windows
X Visual Studio not installed; this is necessary for Windows development.
Download at https://visualstudio.microsoft.com/downloads/.
Please install the "Desktop development with C++" workload, including all of its default components

I have installed it again and don't know why it stays it is not installed!

Any idea how to solve it?

Thank you

3
  • The entire community is dealing with this problem. i suggest try to downgrade for now and be patient. Commented Feb 5, 2022 at 11:17
  • are you referring Visual Studio error that is shown by flutter doctor? Commented Feb 5, 2022 at 11:17
  • @YeasinSheikh Yes Commented Feb 5, 2022 at 11:18

1 Answer 1

4

From your image; you are using Visual Studio Code, not Visual Studio.

Flutter 2.10 arrives with stable support for building Windows app, for more.

Therefore, while running flutter doctor you are able to see this error. If you've plan to build Windows app, you need to install Visual Studio with Desktop development with C++. You need to download and install Visual studio if you wish to remove this error.

You can read more about build for window here.

Sign up to request clarification or add additional context in comments.

5 Comments

Thanks, it solved the error on the cmd, but the error on the left-hand side of the image still exists in VS code, as I still cannot run a fluter command on VS code terminal, any idea?
Does it happen for all project ?
Yes, it does to all projects
For my case, the issue was with PowerShell terminal, after setting system path and restarting the device solved my issue, you can try opening different terminal.
I believe the error is on Powershell/cmd terminal of VS code as well. I have run it throw a separate cmd command and it worked but the embedded cmd, PowerShell terminal on VS code is not working, the connected devices (emulators) weren't also available / connected in the VS code could you throw some light on setting the system Path? is that on the VS code settings? thanks

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.