Installing Umbraco 7 In Visual Studio Via Nuget

Like the majority of the major CMS’s, you can install Umbraco via Nuget.  I’ve talked previously about How To Install Umbraco 7 In Less Than 5 Minutes and How To Install Umbraco 7 Manually. Installing Umbraco via Nuget means you have all your Visual Studio solutions and project files set-up for you as you start developing.

Creating A Blank Website

The first thing we need is to create a folder to store the project files.  After that open up Visual Studio, click File -> New Project.

Umbraco_Create_Clean_Website

Create a new project of type ASP.Net web application and call it whatever you want.  DO NOT USE THE WORD UMBRACO IN YOUR PROJECT.  If you do you will get an error when you try and launch the installer that has:

Parser Error Message: Could not load type ‘Umbraco.Web.UmbracoApplication’.

Source Error:

Line 1: <%@ Application Inherits=”Umbraco.Web.UmbracoApplication” Language=”C#” %>
Line 2:

Source File: /global.asax Line: 1

After you have added your solution name, you need to create the project:

installing_umbraco_nuget_blank_solution

The recommended way is to select the ‘Empty’ option, but you can also select the MVC or WebForms option. The only difference is that you’ll be asked to override the Global.ascx and the web.config.

installing_umbraco_nuget_from_packahe_manager

Next you need to open up Nuget, search for Umbraco and click install.  It’s important you agree to the override prompts that will flash-up, if you didn’t select the Empty option.

After the Umbraco package installs, you will now need to run the Umbraco installer.  This has to be done by loading up your website.  You can do this either in Visual Studio with Cassini, by hitting F5 or, by creating a new website in IIS and pointing it your websites webroot.  When you run your site for the first time, you should now hit the Umbraco installation process.

This first thing you will need to so is set your admin account username and details.  This will be the account you use to log into Umbraco so don’t forget it!

installing_umbraco_login_installer

Before you hit install, you have two options.  First, you can use the default installation settings.  This will install Umbraco into a small SQL Lite database that will be stored within your App_data folder.  The second, more preferable option is to use SQL server.

I won’t cover the details of creating a SQL server account here as it’s quite well documented, but the gist of it.  Is that you will need to create a blank database with a SQL account that can access it.  In this example I’m using the SA account.  Hit the customize button to add in your database preferences.

installing_umbraco_sql_installer

If you have a blank website with the correct details the installer will continue.  If you don’t the installer will complain that it can’t talk to SQL.  If you get an error then you need to look in SQL, not Umbraco.  After you have everything set-up correctly, you can continue with the installation process:

installing_umbraco_sample_site_installer

If you want more information about this process, I’ve previously written about it here.

Conclusion

There you have it.  Installing Umbraco 7 is very easy in all flavors, whether you use the installer, manually install or it use Nuget.  Personally, I prefer to use Nuget as you also get all your visual studio files set-up.

Jon D Jones

Software Architect, Programmer and Technologist Jon Jones is founder and CEO of London-based tech firm Digital Prompt. He has been working in the field for nearly a decade, specializing in new technologies and technical solution research in the web business. A passionate blogger by heart , speaker & consultant from England.. always on the hunt for the next challenge

More Posts

3 replies

Trackbacks & Pingbacks

  1. […] Installing Umbraco 7 In Visual Studio Via Nuget […]

  2. […] written a comprehensive guide about the installation process here, Installing Umbraco 7 In Visual Studio Via Nuget. For a quick re-cap, create a normal MVC project, in Nuget search for Umbraco and follow the […]

  3. […] In case you don’t know how to install Umbraco, then I suggest you read this article, Installing Umbraco 7 In Visual Studio Via Nuget […]

Leave a Reply

Want to join the discussion?
Feel free to contribute!

Leave a Reply

Your email address will not be published. Required fields are marked *