❔ ✅ visual studio code intelisense problem
i'm using Visual studio code to make a .cs script and when i typr in it doesn't register Console.
WriteLine();
and yes, i have the plugin installed
24 Replies
$vscode
1) Install the C# extension
2)
2.a) DO NOT USE OPEN FILE
2.b) Always use
Open Folder
(from the File
menu), and open the folder containing your sln file (or the folder containing the csproj
if you have only one csproj
)
3) To make the extension start and detect C#, either:
3.a) wait for the prompt that will appear on the bottom right of your screen that ask you if you want it to create some files, and say Yes
3.b) Command Palette (F1
or Ctrl+Shift+P
) and type > .Net : Generate Assets for build and run
4) you should see a flame on the Status
bar with the Omnisharp logo (see second attached screenshot)
5) it should load to finally say OmniSharp server is running (if not ask for help)
https://media.discordapp.net/attachments/569261465463160900/1006652191689429022/unknown.png
https://cdn.discordapp.com/attachments/569261465463160900/951015732769079336/unknown.pngit says "Could not locate .NET Core project. Assets were not generated"
have you created a new project ?
using dotnet cli
i'm trying to make a git
Simply making a file called foo.cs will not work.
oh
thank you
hold on
let me try
If you want to create a console application, open command prompt, change to the directory you want to create it in and type
dotnet new console
That will create a new Console Application project.
After that follow the steps that was sent first.
Specifically.
2.b) Always use Open Folder (from the File menu), and open the folder containing your sln file (or the folder containing the csproj if you have only one csproj)
Thank you!!
oh
quick question
👍
now that the neccesary files are there
can i now just make another .cs file
Yes, as long as it's a part of a project.
how do i make it part of a project?
If you opened the folder containing the
.csproj
or .sln
that's all you need to do.Thank you!
i'm learning git for the first time
Good luck.
so i'm very confused about this stuff
thanks
do i need to close this?
or just leave it be
Close what?
Oh, the thread?
yes
type
/close
when you're finished.got it
thank you again!
Was this issue resolved? If so, run
/close
- otherwise I will mark this as stale and this post will be archived until there is new activity.