.NET Command Line Tools (1.0.0-preview2-003133)
Product Information:
Version: 1.0.0-preview2-003133
Commit SHA-1 hash: 74df06500c
Runtime Environment:
OS Name: Windows
OS Version: 6.1.7601
OS Platform: Windows
RID: win7-x64
VS Code version: 1.6.1
C# Extension version: 1.5.0-beta4
Follow the example images.
This is the standard Visual Studio Pro intellisense:
Example Case 1: Enums.



Example Case 2: Initializations.


This not only could save a lot of typing, but also save a lot of frustration when coming from environments like VS Pro :)
Thanks! :+1:
@DustinCampbell I noted that this issue received no labels. Do you want/need more details?
@DustinCampbell for what I understand from other threads is that omnisharp already has this information, this would only require to implement the autocomplete, that is correct?
@Novack- OmniSharp has access to this information, but we need a new endpoint to expose it. That's a bigger work item that I'm tracking here: https://github.com/OmniSharp/omnisharp-roslyn/issues/78.
Above, you mentioned to specific completion features that we have in Visual Studio:
Awesome @DustinCampbell thanks for the update. I will be following the events!
Any progress changes on this? I have been following the referenced threads without any luck either.
While I enjoy working with VSCode, I can't use it daily for proffesional work until I can achieven the same level of productivity and smooth code writing than I get on other environments.
We really need feature parity in terms of code completion!
6 months now. I dont think this request is exotic, I consider it basic functionality, but meh! Maybe is just me. Moved away from code months ago, will check from time to time if its improved.
Sorry for the delay on this, but most effort has gone toward making sure that we have parity in VS Code for .NET Core .csproj projects with what we previously had with project.json projects.
Looking a little more closely, it looks like we're going to need an API from VS Code to be able to support this. AFAICT, VS Code does not support specific _selection_ in the completion list, which is what this feature requires.
Would you elaborate on what you mean by _supporting specific selection in the completion list_?
There's two problems here:
It's those two behaviors that make the features you've described here really great in Visual Studio. An enum gets selected in the list based on the current context in the code. E.g. if you're in the position of an argument list that would take an enum, that enum gets selected to make typing easier. Bringing up completion on "new" is similar. Recent changes will put the correct suggestion in the list, but it won't be selected until you type more characters. Does that make sense?
Oh, yes does much more sense. Thanks.
Bollocks! This seemed like so near when I createds the ticket...
It's OK. I'll file an issue to get what we need in VS Code.
No news yet?
Sorry that I haven't updated this issue in awhile. We're tracking a lot of this work on https://github.com/OmniSharp/omnisharp-vscode/issues/1765. No. 1 from my list above should be done. However, No.2 is still outstanding. cc @rchande
Hello guys! Two years :)
Any news? Thanks!
@Novack In the latest version of the C# extension I am able to see the completion for "new" with the dictionary completion preselected as well. Do you think this issue is fixed now or is there something that is still missing out
Hello @akshita31 thank you for the quick reply. I have not been using vscode recently, didn't knew this was solved.
I will check it and poke back. Lists, enums, dictionaries are a few examples. And not just on instantiation, also when passing parameters and such, are things I'd like to confirm.
For some reason is not working for me, not with dictionaries, nor lists, and neither auto displays autocompletion list for enum parameters, and stuff like that.
Im not sure if its a problem on my end, or not, because setting up code with unity can be tricky sometimes, and I only did now for this test.
Speaking of the wider context, is not just looking at dictionaries tbh, if you see the issue reported, there is more to it: would be basically interesting to have feature parity with Visual Studio regarding intellisense. Stuff like this is common in every code editor out there.
There was a bug in previous versions of vscode where preselected items were not properly focused in the dropdown: https://github.com/Microsoft/vscode/issues/63245. Can you check if you have problems with the latest version of VSCode (that just came out today)?
Finally got time to get VSCode working with Unity again... Now Omnisharp is working, but for the topic of this thread, not even the basics are working:


Some cases indeed seem a problem of focus on the right item of the completion list, because if I keep typing, it shows the item is actually there:

But for Enums, it doesnt work at all, nor for new variables, not for method calls autocompletes:

@Novack It seems to work very reliably for me on 1.31 insiders. What build of VS Code do you have?
@rchande Im using latest VSCode (1.30.1) with corresponding Omnisharp (and Unity).
Most helpful comment
Sorry for the delay on this, but most effort has gone toward making sure that we have parity in VS Code for .NET Core .csproj projects with what we previously had with project.json projects.