vscode replace code example

Example 1: How do I find and replace all occurrences (in all files) in Visual Studio Code?

Ctrl+Shift+H

Example 2: visual studio find and replace

//Press Ctrl+F as a shortcut to find a string in the current file.
//Press Ctrl+H as a shortcut to find and replace a string in the current file.

Example 3: multiple word select in vs code

//Selects the word at the cursor, or the next occurrence of the current selection.
Ctrl+D 

//To add cursors to all the occurrences of a highlighted word 
Ctrl+Shift+L 
//Then select all occurrences of that word

Example 4: substitute everything visual studio code

Click on the left bar the search icon
Then with the symbol at the right side of the input field decide if apport the substitution to all files

Example 5: how to replace text for same words vs code

(1) Select your code

(2) Ctrl+Shift+L (which is editor.action.selectHighlights)

(3) voila, multiple cursors done - type away.

Tags: