Does visual studio really not come with basic syntax checker? I've got both 2008 and 2010 and they won't show me any error, like missing semicolons or unmatched brackets
The closest advice I've found is to enable tools -> options -> text editor -> C/C++ -> Advanced -> Underline Errors in the editor, which doesn't exist
I figured it out..
"CLR Empty Project" doesn't have this functionality for some reason, "Empty Project" does however.
I think C++ projects do not get active syntax checking like the counter parts in .NET languages. The errors will only appear when you build the project.
Tools->Options->Text Editor->c/c++->General-> unchecking "Word wrap" (under settings) could solve the problem. Thanks
Related
Typescript 1.4 has been released recently, providing new possibilities like unions.
I installed the new version for Visual Studio, however the syntax highlighting doesn't recognise unions:
var member: string|number;
Although it can be compiled without problems, the syntax checker hovers the definition and any usage of the variable member.
What do I need to update to get this working?
Rather than turning off Resharper, you could configure it to ignore analysing errors in *.ts files. (Tools -> Options -> Resharper Options -> Code Inspection -> Settings -> File Masks to Skip -> add *.ts)
This way you still benefit from using Resharper for other files, and you also get the benefits of code formatting and the like for TypeScript using Resharper.
I was having a similar issue where Resharper was not recognizing the "const" keyword.
I fixed this by explicitly telling Resharper what version of TypeScript to use. By default it is set to "auto detection".
On the menu, go to Resharper > Options > Code Editing > TypeScript.
Change the Type Script Language Level to "1.5 (experimental)"
I've had the same issue, and for me it was Resharper that was causing the problem.
If you have Resharper installed then simply disable it while working on TypeScript 1.4, at least until JetBrains releases an update with 1.4 support.
To disable Resharper:
Tools -> Resharper -> General -> Suspend
How can I disable spelling check in Visual Studio 2010? By spelling check I mean in comments, string etc, not in actual code
In the Visual Assist X Options dialog on the Underlines page, uncheck the "Underline spelling errors in comments and strings" option.
Cory - This will disable syntax highlighting.
This is probably an extension you have installed. You needs to disable it in the extensions manager or configure it not to check spelling.
http://blogs.msdn.com/b/yardman/archive/2011/02/01/visual-studio-2010-spell-checker.aspx
For example in my install spell checking is provided by Visual Assist. If I disable this extension then the squigglies in comments go away.
I'm fairly certain VS2010 doesn't have a built in spell-checker, however, the C/C++ options contain IntelliSense which can cause "red squiggles." Here's how to disable those:
Tools -> Options -> Text Editor -> C/C++ -> Advanced
Under "IntelliSense" will be an option called "Disable Squiggles." Set it to true.
Had this problem in Visual Studio 2019. Turned out it was my Resharper extension. Extensions->Resparper->Options->Tools->Respeller->Enable Respeller (uncheck)
in javascript I solved this by going to Tools > Options > TextEditor > Javascript > advanced > Uncheck Show Syntax Errors.
For example, when I write:
string x = "turtle";
x.Go();
There is no red squiggly line detecting the absence of the Go() method on String.
Only when I compile does the error get detected.
I've just upgraded to Windows 7, I have Visual Studio 2008.
In my old environment the errors were detected before the actual compile.
Is there a setting that I am missing?
EDIT: "Tools -> Options -> Text Editor -> C# -> Underline errors in the editor" is checked.
I dont have the "Live Semantic" option. Maybe I need to go to SP1?
You need to turn on the underline errors in the editor and show live semantic errors options in Visual Studio.
These options can be found here:
Tools > Options > Text Editor > C# > Advanced > Editor Help
Edit: You will need to install SP1 for this functionality to work.
Select Tool -> Options, then Text Editor. Under the language you are using (ie C#), go to the Advanced and make sure the Underline errors in the editor and Show live semantic errors are checked
Stop the project.
Open Folder Project.
Delete .vs folder (he is a hidden folder)
Then restart Visual Studio
EDIT:
This approach has been around since the 2012 version of Visual Studio. This folder consists of keeping all breakpoint information and other settings saved. It is not known why, the configurations arrive at a time when the errors of compilations no longer appear. Deleting the .vs folder will "reset" your breakpoints forcing you to do them again if you need to.
For visual studio 2015 and higher:
Go to: Tools > Options > Text Editor > C# > Advanced > Editor Help
Then select: Enable Full solution analysis
I had the same issue and had SP1 installed and had Underline errors in the editor and Show live semantic errors checked in VS2008's options.
My solution was to download Microsoft Visual Studio 2008 Service Pack 1 (Installer) and re-install the package. It wasn't classified as a 'repair' or a 're-install' despite the fact it was already installed, but it worked.
Restarting VS solved my problem once.
my solution; I know it won't help like 80% of the viewers, but for the sake of who it will:
i have had a lot of noise in the IOS part of the solution, a VS bug that showed a lot of errors that weren't supposed to appear, so I just deleted the IOS part because I didn't really needed it as I didn't even had a Mac server to test it on... Something happened after that and the squiggly line returned! Seriously, VS team, fix your bugs...
JavaScript Type Checking
Sometimes type checking your JavaScript code can help you spot mistakes you might have not caught otherwise. You can run the TypeScript type checker against your existing JavaScript code by simply adding a // #ts-check comment to the top of your file.
// #ts-nocheck
let easy = true;
easy = 42;
Tip: You can also enable the checks workspace or application wide by adding "javascript.implicitProjectConfig.checkJs": true to your workspace or user settings and explicitly ignoring files or lines using // #ts-nocheck and // #ts-ignore. Check out the docs on JavaScript in VS Code to learn more.
In my case the problem was that I created a file with .s extension instead of .cs an then changed the extension to .cs once it was created.
I deleted it and created again correctly and now VS is underlining the errors in this file.
VS2008 has nice enum suggestions eg if you press space after "=" and enum value is expected it automatically suggest all enums.
Noticed it gone after installing R#
Do you know how make it working back ??? Lack of this is really pain...
It's a bug that has been reported here. If you'd like to encourage JetBrains to fix it, sign up on their Jira site and vote/watch/comment on the bug.
There is no workaround apart from not using Resharper at all.
You may want to disable the R#'s IntelliSense (and use VS buit-in IntelliSence instead).
In Visual Studion, goto ReSharper (menu) -> Option -> IntelliSense -> General -> Visual Studio
I'm using R# 6
My Visual Studio (2008) Editor has stopped to underline Errors (this nifty wavy red lines). I can't really tell when, but it can be related to the installation of .Net Framework 3.5 SP 1 or the MVC Beta (which I guess is unlikely). Furthermore have I installed and uninstalled both CodeRush and Resharper for evaluation purposes (decided not to keep either one of them).
Does anyone know the problem and how to restore this functionality again?
Have you checked Tools→Options...→Text Editor→C#→Advanced→Underline errors in the editor?
I usually like to reset my settings after messing around with plugins, as they tend to mess with settings: Tools→Import and Export Settings...→Reset all settings.
About possible causes.
For VS 2012 and 2013 if you have more than one instance of Visual Studio on different machines binded to one "live" account and have installed ReSharper on one of them, it disables the native IntelliSense and error underlines (to replace by it's own rules) that will be synchronised through your account to another machine without ReSharper.
Found it in Visual Studio 2019 as: Tools > Options > Text Editor > General > Show error squiggles
This is generally called Disable Squiggly or Wavy lines in Visual Studio.
How you will do in Visual studio 2013?
TOOLS -> Options... -> Text Editor -> C/C++ -> Advanced -> Disable Squiggles: True/False (Under IntelliSense) -> Press OK
I know its an old question, and with various solutions, but I have fixed it in different way. I'm working with Unity3D on my C# code using VS2017, when suddenly VS decides to stop underlining error while im typing. However, if I close the file tab and reopen, it suddenly undelines the error.
For example:
class A {
public int x;
s;
}
should obvsiouly give an error for that lonely 's' symbol. But, VS doesn't underline it until I close and reopen this file tab.
Solution:
Copied the entire Unity Project folder (which is like a regular VS Solution folder basically) and worked with the new folder, which issue was gone there.
For visual studio 2017 act according to HeeJae's comments in:
https://developercommunity.visualstudio.com/content/problem/113112/design-time-error-checking-isnt-working.html
i.e:
Hi. you are probably hitting a known issue. can you try this?
1.Update to latest release If that doesn’t solve it
2.Go to Tools\Options\Projects and Solutions\General and uncheck “Allow parallel project initialization”.
3.Close VS.
4.Delete the “.vs” directory beside their solution file.
5.Reopen VS.
..
thank you
You can re-enable the "Allow parallel project initialization" option after the issue was solved.
I tried to upgrade VS, reset VS settings, clear VS cache and everything people do conventionally but none of them solved this issue! At the end the mentioned solution worked for me magically.
Good luck
Unloading and loading same project again from the solution does the trick. Just right click on the project and click "Unload Project". Once unloaded, again right click the same project and click "Reload Project". Error highlighting will return.
I had the same issue with 2017. There was a 'disable intelisense' option, make sure that is set to false.
For everyone wondering in 2021..
search for "C_Cpp.errorSquiggles" in the settings.
Make sure to have it active for the user, as well as the workspace.
No need to restart Visual Studio.
For me (VS 2019) , after trying the other answers also, setting the scope of analysis from "Current document" to Open document" brought back the missing error markers
Just go to settings and search for errors and Image in Error Squiggles. You can see the Error squiggles (Modified: Workspace - Right now you can't see it because I modified it). Just click on modified and you will see the disabled option. If by mistake you disabled it, just enable it and you can see the red line errors again in your code.
In latest edition, check for .vscode folder in same project folder. There will be a setting.json file in that. Delete the key value pair of "C_Cpp.errorSquiggles": "Disabled". Restart the vs code.