

This feature gives you immediate feedback on misplaced or missing braces. When the insertion point is placed on an open brace in a code file, both it and the closing brace are highlighted. Look for Syntax Error, Compiler Error, Warning, and Other Error. You can see the default color for each error and warning squiggle in the Tools > Options > Environment > Fonts and Colors dialog box.

Quick Actions suggest fixes for problems and make it easy to apply the fix.

Red squiggles denote syntax errors, blue denotes compiler errors, green denotes warnings, and purple denotes other types of errors. You can see the default color for each type, and you can change the color for any specific syntax element in the Fonts and Colors, Environment, Options dialog box, which you can open from the Tools menu.Īs you add code and build your solution, you may see (a) different-colored wavy underlines (known as squiggles) or (b) light bulbs appearing in your code. C++ uses color to differentiate among types, enumerations, and macros, among other tokens. Other syntax elements are also colorized, such as string literals and comments. For example, keywords (such as using in C# and Imports in Visual Basic) are one color, but types (such as Console and Uri) are another color. Some syntax elements of code and markup files are colored differently to distinguish them. Many of these differences are specified in the descriptions of the features, but for more information you can see the sections on specific Visual Studio languages. The different Visual Studio languages offer different sets of features, and in some cases the features behave differently in different languages. For more information, see Use regular expressions in Visual Studio. You can use regular expressions to find and replace text. For more information, see Find and replace text.

You can search and replace text in single or multiple files. You can click on the Class View tab at the bottom of the window to view your code organized by classes. By default, Solution Explorer shows your code organized by files. You can view your code in a number of different ways. For Visual Studio for Mac, see Source editor (Visual Studio for Mac). This topic applies to Visual Studio on Windows.
