Getting Started with Visual Studio

If you still need to install Visual Studio, check out our earlier article.

Build an App with Visual Studio 2017

by Nicole Bruck

Step 1: Create

We’re going to create an ASP.NET web app to display, “Hello, World!”

  • Select File → New → Project…

 

  • Under Web, choose the “ASP.NET Web Application” project type and name it: “HelloWorld”

Step 2: Edit

We’re going to edit the title of our web app to display a new message.

The project welcome page shows several links to help you get started.  If you just run the project immediately this page will be the default page in the website, so you can dig into how it is built to learn more.  For our purpose, we’re going to add a simple page to the project to keep things clean and clear.

  • In the Solution Explorer, right click on the project “Hello World” > expand the Add menu option > and select HTML page, and type in HelloWorld for the page name.
  • The new page should load in the editor and have focus by default, if not go ahead and find it again in the Solution Explorer in the top right and double click (single click provides a temporary preview in the editor window).
  • For this new page, we’re going to update the title, add a couple lines in the body, and a footer.  You can do more or less if you’d like.

Step 3: Build & Run

Now we’re going to build the project so we can make sure that all the code works.

  • The start button has a drop-down, this lets you choose the default browser to launch the website using (as well as add new browsers to run under).
Once you’ve clicked the start button (green arrow next to the browser name) your site will spool up and launch in that browser.

  • Note that our new page is in the active tab, while the page that comes with the project is in the other tab.

 

  • Be aware, closing the browser window does not kill the website.  To return to an edit mode you’ll have to click the red square to end the debug session.  The performance window is the give-away that the site is still running – you can see that in the window on the right.

And with that we know enough to stand up a page and work with it locally, congratulations.  From here the hints and links on the default page can help you build more complex applications, add services, and even deploy to Azure.



If you’re ready to start trying out some of our debugging features, head to our next article: Debug & More.