Presentation is loading. Please wait.

Presentation is loading. Please wait.

Keith Elder Microsoft MVP

Similar presentations


Presentation on theme: "Keith Elder Microsoft MVP"— Presentation transcript:

1 Keith Elder Microsoft MVP http://keithelder.net/blog/

2 What Does Visual Studio Do? It is your IDEIt is your debugger It allows you to connect and manage databases and other servers It allows you to manage all of your projects via source control It allows you to build and deploy your software deliverables It allows you to write code faster. Unit TestingLoad TestingIt is your friend.

3 Start Screen of Visual Studio Dockable Windows Solutions and Projects Files are opened in tabs.

4 Your First Project

5 First Project: Console Application Basics You get a solution even though you didn’t ask for it Projects are green in C# Solution Facts

6

7 A solution is a deployable software deliverable. It is just a plain text file. The extension is.SLN There is also a user options file. A solution is made up of one or more projects. Solution folders allow devs to organize larger projects.

8 Solution Facts – File System Tip: User options should never be checked into source control. Most things in Visual Studio map directly to the file system.

9 Solution Facts – Solution Folders Tip: Solution folders aren’t “real” folders.

10

11 Project Facts Projects contain your code Projects are broken up based on separation of concerns Each file you see in a project relates precisely to a file in your file system. Projects are XML files Projects reference DLLs Projects can reference other projects Adding a folder to a project, adds a folder to your file system Different solutions can reference different projects.

12 Project Facts - Just XML

13 Solutions and Projects

14

15 Building Software: Ctrl-Shift-B The key shortcut ctrl-shift-b is how you can test your project to see if it compiles. Build errors show up in the Error List. Double click an error to jump to that line in your solution.

16 Build Configurations Configurations Provide Different build types (debug or release) Different CPU builds Which projects should or should not be built.

17 Build Facts The configuration determines where files will be copied to by default Project dependencies are built first, then the main project At least one solution must be set as the startup project Class library projects cannot be set as the startup project

18 Building your software

19 My code is perfect! How about yours?

20 Debugging Facts Allows you to stop your program in mid execution Provides full access to variables Start by setting a break point Press F5 to launch VS in debug mode Supports conditional break points F10 – Step over F11 – Step into Shift-F11 – Step out

21 Debugging – Visualizers

22 Debugging – Quick Watches

23 Finding those bugs

24

25 Coding Facts Intellisense as you type Ctrl-Space – shows intellisense window Code snippets save repetitive tasks Write your own! If you see code that has a red underline at the end, pay attention! Ctrl-K-C – comment code Ctrl-K-U – uncomment code Shift-Alt-down – highlight code in a block Ctrl-F – find text Ctrl-H – search and replace Ctrl-K-D – reformat document Bookmarks – mark your place and go back Ctrl-Tab – toggle between open files

26 I didn’t know I could code this fast!

27 Links Sara Ford – Visual Studio Tip of the Day http://blogs.msdn.com/saraford/ http://www.amazon.com/Microsoft-Visual-Studio-Tips- Sara/dp/0735626405/ref=sr_1_1?ie=UTF8&s=books&qid =1225990469&sr=8-1 http://www.amazon.com/Microsoft-Visual-Studio-Tips- Sara/dp/0735626405/ref=sr_1_1?ie=UTF8&s=books&qid =1225990469&sr=8-1 http://tinyurl.com/deepfried15 (podcast with Sara) http://tinyurl.com/deepfried15


Download ppt "Keith Elder Microsoft MVP"

Similar presentations


Ads by Google