Build Your First Cloud Application Using Visual Studio 2010
page 3 of 5
by Vince Varallo
Feedback
Average Rating: This article has not yet been rated.
Views (Total / Last 10 Days): 30277/ 68

Step 2: Create a New Solution

1.   Launch Visual Studio 2010.

2.   Select FileàNew Project… from Visual Studio's menu.

3.   Expand the Visual C# templates and click on the Cloud node.  You should see the Windows Azure Cloud Service template.

4.   Change the name of the project to "MyCloudService" and click the OK button.

5.   The New Cloud Service dialog box should appear.

6.   Click on the ASP.NET Web Role in the left pane and click the > arrow to move it to the right pane.  This allows you to create a traditional ASP.NET web site for the cloud.  You can create a MVC web site, WCF service, background process or GCI application but for this example we'll stick with the traditional ASP.NET web site.

7.   Click the OK button.

8.   Visual Studio will add a whole bunch of standard files for a typical ASP.NET application. Some of these files include a master page, the login and password management pages, a style script, an about page, and a scripts folder. 

9.   Click the run button to start the project.  You should get the following message.

10. To remedy this you need to close Visual Studio and then launch Visual Studio again as an administrator.  You can do this by clicking on StartàAll ProgramsàMicrosoft Visual Studio 2010 and then right click on Microsoft Visual Studio 2010.  Select "Run as administrator" from the pop-up menu.  Now you need to open the MyCloudService project again.

11. Now try running the project again.  If you don't have SQL Express installed you'll get the following message.

12. The Output window will give you a more descriptive message.

"Windows Azure Tools: Failed to initialize Development Storage service. 
Unable to start Development Storage. Failed to start Development Storage: 
the SQL Server instance ‘localhost\SQLExpress’ could not be found.   
Please configure the SQL Server instance for Development Storage using the
‘DSInit’ utility in the Windows Azure SDK."

13. To fix this open the Windows Azure SDK Command Prompt.  This is found at StartàWindows Azure SDK v1.2àWindow Azure SDK Command Prompt.

14. Enter the following in the command window.

dsinit /sqlinstance:.

15. You should see the following dialog.

 

16. Click the OK button and then run the project again.  You should see the following web page.


View Entire Article

User Comments

Title: Nice tutorial   
Name: shivam india
Date: 2012-04-02 6:22:45 AM
Comment:
Nice tutorial for starters. i created my application and hosted successfully.works fine....
Title: Nice   
Name: Waseem-Pakistani
Date: 2011-03-02 2:50:50 AM
Comment:
Good intro and basic discussion. looking forward to move towards that.
Title: very nice   
Name: christy
Date: 2011-02-17 5:33:13 AM
Comment:
We r tring to implement.Thanks for your guidance.
Title: Nice Introduction   
Name: Bijith K B
Date: 2011-01-01 1:33:59 PM
Comment:
It was a nice walkthrough.

Product Spotlight
Product Spotlight 





Community Advice: ASP | SQL | XML | Regular Expressions | Windows


©Copyright 1998-2024 ASPAlliance.com  |  Page Processed at 2024-10-15 11:36:46 PM  AspAlliance Recent Articles RSS Feed
About ASPAlliance | Newsgroups | Advertise | Authors | Email Lists | Feedback | Link To Us | Privacy | Search