This is the eleventh part of the 11 series LightSwitch tutorial. In this part we will learn about how to Publish LightSwitch Application as Web Application and host in IIS.
Table of Content
- Aim of the article
- Steps to Publish LightSwitch Application as Web Application and host in IIS
Rapid business application development is a need of today’s business and keeping that in focus software stewards wants to build the 3 tire applications at a lightning speed where there will be less code, less time will be spent on designing the UI screens , the BAL layer and DAL layer. By keeping all these into focus, on 26th July, 2011, Microsoft has released their new product – LightSwitch.
It is the simplest way for developers of all skill levels to develop business applications for the desktop as well as for cloud. This is the eleventh part of the series of 12 LightSwitch tutorials where we will look into how to Publish LightSwitch Application as Web Application and host in IIS.
You can read the other parts of the LightSwitch tutorial as under
- Part 1: Introduction to Light Switch
- Part 2: Rapport with New Data Screen
- Part 3: Rapport with Search Data Screen
- Part 4: Rapport with Editable Grid Screen
- Part 5: Rapport with List and Details Screen
- Part 6: Rapport with Details Screen
- Part 7: Rapport with External Data Source – Database
- Part 8: Rapport with External Data Source – WCF RIA Service
- Part 9:Using a custom control in LightSwitch
- Part 10: Publish LightSwitch Application as Desktop application and host in local system
- Part 11: Publish LightSwitch Application as Web application
The article assumes that, we have LightSwitch 2011 installed in our system
Now that we have seen how to build the various screens, using user control in our LightSwitch application, now we can go ahead for the deployment operations.We can host on the LightSwitch applications on the desktop, on a remote IIS Server or in Azure.In this article we will look into how to perform the hosting in a desktop.
Step1:From Visual Studio, first choose Configuration Manager from Build tab
Step 2: The Configuration Manager window appears.From the "Active solution configuration" dropdown, choose "Release". And then click on "Close" button.
Step 3: Next, again go to the Build tab and choose Publish <Project Name>. Note that our LightSwitch Project name is Application1.So we are choosing Publish Application1
Step 4: The LightSwitch Publish Application Wizard will appear with 8 steps.
- Client Configuration
- Application Server Configuration
- Publish Output
- Database Connections
- Prerequisite(appears only if we choose to publish the LightSwitch Application as Desktop.Does not appear in case of Web)
- Other Connections
- Specify a certificate
In the Client Configuration, we have to option to choose as how the LightSwitch Application will be deployed viz. Desktop or Web.We will choose the Web option and click on "Next" button.
Step 5: Now we are in the Application Server Configuration section. In this section, we will be asked as where the application will be hosted viz. Local, IIS or Windows Azure. We will choose IIS and click "Next" button to proceed further.
Step 6: Now we are in the Publish Output section. In this section, we need to specify how we want to publish the website. We will choose "Remotely publish to a server now" option.Click "Next" button to proceed further.
Step 7: Now we are in the Database Connections section. In this section,we need to speficy the administrator and user database connections and click on "Next" button.
Step 8: Now we are in the Other Connections section. In this section, we need to speficy if our data comes from any other sources or not. Then click "Next" button.
Step 9: We are now in the "Specify a certificate" screen. If we need to add any certificate for adding a Xap file, we need to do so here. In our case, we can leave it as default and click on the "Next" button to proceed further
Step 11: Now we are in the "Summary" screen which gives a basic summary of our application.Next click on the "Publish" button
And that's all we need to do.
So in this part we have learn about how to Publish LightSwitch Application as Web Application and host in IIS.
Thanks for reading the article.Happy lightning with LightSwitch.