cannot open source file "iostream". Please run the 'Select IntelliSense Configuration...'

Justin C 0 Reputation points
2024-11-16T00:21:18.11+00:00

This problem popped up out of nowhere in the middle of October.

" cannot open source file "iostream". Please run the 'Select IntelliSense Configuration...' command to locate your system headers.C/C++(1696) "

I'm getting this error in all of my files. I've tried uninstalling and reinstalling, changing the complier path, the Include path, and I've tried changing "c_cpp_properties.json" file, but nothing seems to work.

I am on a MacBook Air btw. The same problem happened on my PC, but I was able to fix that by following the instructions on the VSC website. But nothing seems to work for my Mac.

Can some one please help?
(I've included a simple code to show the problem)

User's image

(This is what my c_cpp_properties.json look like)
User's imageUser's image

Visual Studio
Visual Studio
A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.
5,232 questions
C++
C++
A high-level, general-purpose programming language, created as an extension of the C programming language, that has object-oriented, generic, and functional features in addition to facilities for low-level memory manipulation.
3,776 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Tianyu Sun-MSFT 31,416 Reputation points Microsoft Vendor
    2024-11-18T01:50:35.75+00:00

    Hello @Justin C,

    Thank you for taking time to post this issue in Microsoft Q&A forum.

    As Visual Studio Code(VS Code is different from VS IDE) is currently not supported in the Microsoft Q&A forums, please kindly post your question on Github - vscode for better help.

    Thanks again for your understanding.

    Have a nice day,

    Tianyu


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.