Adding Cloud Service project to existing ASP.Net Web Application

Imagine we are moving existing Web Application or ASP.Net MVC Web Application to cloud. In that case we need to add cloud service to existing Web Application or ASP.Net MVC Web Application.

We have a solution for Web Application is as below,

clip_image001

Now right click on the solution and add a new project in the same solution. Choose Windows Azure project from the installed template and then choose a ASP.Net Web Role.

clip_image003

In role selecting window do not select any role and click on Ok. See the image below,

clip_image004

Now you can see in solution explorer, Windows Azure project is being added.

clip_image005

After creating Windows Azure project we need to associate ASP.Net Web Application project to Window Azure. So to do so, Right click on Roles in Windows Azure Project and select add and then choose Web Role Project in solution option

clip_image007

Then you will get the project in the solution. Press ok

clip_image008

On clicking of Ok, Visual studio will update csdef and cscfg file for the Web Role.

Now add the references of required windows azure. For that click on web Application project and add references. Then add the below references.

clip_image010

In this way you have added cloud service project to existing Web application.

Advertisements

One thought on “Windows Azure for Developers task 2: Adding Cloud Service project to existing ASP.Net Web Application

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s