2. If I had eight hours to chop down a tree,
I'd spend six sharpening my axe
- Abraham Lincoln
3. What do you want most from
an IDE?
It is just me -
Assist me write good (hopefully) code fast
and happily
4. Let us make a great IDE
better
Launch VS.NET quickly
Organize views and windows
Choose color scheme and font
Master some shortcuts
Do not repeat yourself using macros
Extend VS.NET using addins
Use command window
6. Choose the right start up
option
Show Start Page
Load last loaded solution
Show Open Project dialog
box
Show New Project dialog
box
Show Empty environment
9. Start VS.NET from command
prompt
C:> devenv /nosplash c:weicsharpproj1proj1.sln
c:weicsharpproj1
Prerequisite
Put C:Program FilesMicrosoft Visual Studio .NET
C: Files
2003Common7IDE into your path
2003Common7IDE
11. Litter your desktop with a
solution shortcut
Double click it to open the solution
12. A little more about working
with command prompt
C:>devenv /?
C:>devenv c:weitrialcsharpunit_testunit_test.sln
/build DEBUG
Why? Automation and continuous integration
19. Little thing counts
Add guide lines to Visual Studio.Net Text Editor
Subtle effect: do not write a line which is too long
20. Add guide lines to Visual Studio.Net
Text Editor
Open regedit
HKEY_CURRENT_USERSoftwareMicrosoftVisualStudio<7.1>
Navigate to HKEY_CURRENT_USERSoftwareMicrosoftVisualStudio<7.1>Text
Editor
Right-click on the Text Editor key and choose New String Value and name it
"Guides"
Set the value of the guides to RGB(92, 46, 46) 80, 100
21. Text editor color scheme
Customize a combination which is best for
your eyes
23. Text editor color scheme
sample
Source: http://seizethedave.com/etc/ide-color.gif
http://seizethedave.com/etc/ide-
24. Text editor color scheme
sample
Source: http://www.codinghorror.com/blog/archives/000682.html
25. Text editor color scheme
sample
Source:
http://www.codinghorror.com/blog/archives/000682.html
26. Font for text editor
Choose a font that works best for your
eyes
27. Font size for text editor
Choose a font size - I choose a larger font
size 14.
Why?
• Good for my eyes
• Seeing a lot less code in the editor at a time helps
write better code. You naturally want see a whole
method in one go. Seeing less code has the subtle
effect of writing shorter and cleaner method.
28. Shortcuts
Tons of them
Lots of them you never use
Lots of them you do not care
Master 10 – 15 killers that you use all the
time
29. Shortcuts
Ctrl + Space
Complete the current word or shows all available methods
and properties for a class
Ctrl + Shift + Space
Show the parameter information when the cursor is inside
method parentheses
30. Shortcuts
Ctrl + K Ctrl + I
Show a quick description about whatever object the cursor is
currently resting on
34. Shortcuts
F8
Next item in the task list or search results.
Killer usage:
Search for something in the whole solution
From command window: grep “wordtosearch”
Then hit F8 for the results
35. Shortcuts
F12
Go to definition
Shift + F12
Go to reference
37. Shortcuts
F5
Start with debugger
Ctrl + F5
Start without debugger
F10
Step over
F11
Step into
38. Shortcuts
Esc
Set the focus back to code view (editor)
Ctrl + Tab
Go to the next opened file in the text editor
39. And do not forget
Ctrl + S
Save the current file
Not just for VS.NET
Ctrl + Shift + S
Save all modified files
40. And do not forget
Shift + F10
= right click
Bring up context menu
It works not only for VS.NET
41. Create your own shortcuts
Tools->Options->Environment->Keyboard
Tools->Options->Environment-
42. My customized shortcuts
alt + s Solution viewer
alt + c Class viewer
alt + p Property Viewer
alt + f Find File
alt + o Opened file
alt + a All members of the file
alt + m Methods of a file
alt + v Pending checking
alt + r Output viewer
alt + t Options window
alt + h View history of the file under editing
43. Shortcuts
List all shortcuts and print it out for
reference
Use a macro available here:
http://www.codinghorror.com/blog/archives/000315.html
44. Macros
A series of commands and instructions grouped
together
Automate repetitive actions
49. VSFileFinder2003
Find files quickly in large solution with many projects
Freely available from:
http://zero-one-zero.com/vs/
http://zero-one-
A must
56. QuickCode .NET
Write code for you
Give you more time to code other things that you really
want to spend time on
Available from:
http://www.dvxp.com/en/QuickCode.aspx
61. Solvent
Recursive Expand/Contract
Open All Sub Items
Open Containing Folder In Windows Explorer
Command Prompt Here
http://www.paraesthesia.com/blog/comments.php?id=602_0_1_0_C
62. VIEMU
vi-vim emulation for Microsoft Visual Studio
Vi/Vim is an text editor which allows you to edit code
quickly
Not a freeware
Not for everyone due to its key binding
http://www.viemu.com/
63. VIEMU - Demo
h j k l - move around quickly
gg - go to the beginning of a file
G - go to the end of a file
:15 - go to line 15
yy - copy a line
p - paste
:w - save the file
:q - close a file
:qa - close all files
:prb - build the project
64. Addins
Bring up addins using shortcuts and command aliases
This makes addins really powerful
65. Command window
The hidden treasure of VS.NET
Can be used to do pretty much everything
My control center for VS.NET
66. Command window
What can you do from command window?
Bring up views, windows
Build project and solution
Search for something
…
You name it
67. Command window - Demo
Important: create a shortcut to bring up command
windows first
Mine is alt + w
71. My question to you
What shortcuts, tips and tricks you use all the time?
72. Being productive
Tools matter but it is not only about tools.
It is about a mind set.
Nobody has time for it. Make it. Dig it.
It pays off.
73. If you save 10 minutes a day
Is it a big deal?
Let us do the math:
10 (minutes/day) * 300 (days)
= 3,000 minutes
= 50 hours
= One whole week
Plus, chances are you will save more than 10 minutes a
day!
Plus, you now can code in a better mental mood ☺