65.9K
CodeProject is changing. Read more.
Home

Display line number in Visual Studio

starIconstarIconstarIconstarIconstarIcon

5.00/5 (4 votes)

Jan 22, 2011

CPOL
viewsIcon

19612

I know that some people like to have line numbers and it is particularly useful if you are sending code to somebody else, like posting it on CP in Q&A when asking for help with a problem, for example. In cases like that, it is much easier to say "the error is on line 123".However, I don't...

I know that some people like to have line numbers and it is particularly useful if you are sending code to somebody else, like posting it on CP in Q&A when asking for help with a problem, for example. In cases like that, it is much easier to say "the error is on line 123". However, I don't like to have them on all the time so, provided that you haven't changed the default key-mappings simply type Ctl-g, enter the line number and press return. You get taken straight to the appropriate line.