Export (0) Print
Expand All

How to: Host a LightSwitch HTML Client Application on Sharepoint

By using Microsoft LightSwitch for Visual Studio Update 2, you can create SharePoint apps that are hosted in the SharePoint Store or in your organization's private app catalog. By enabling SharePoint debugging, you can also host your app on SharePoint to test it during development.

To enable SharePoint debugging

  1. Create an application by using either the LightSwitch HTML Application (Visual Basic) or LightSwitch HTML Application (Visual C#) template.

  2. In Solution Explorer, open the shortcut menu for the Properties node, and then choose Open.

  3. On the SharePoint tab, choose the Enable SharePoint button.

    The Add SharePoint dialog box opens.

  4. In the What SharePoint site do you want to use for debugging your App? text box, enter the URL for your SharePoint site.

    If you’re prompted for credentials, enter your SharePoint credentials.

  5. Choose the Validate button to ensure that the connection is valid, and then choose the OK button.

    When you run the application, it will now be hosted on SharePoint instead of in your browser.

To publish a SharePoint app

  1. In Solution Explorer, open the shortcut menu for the Project node, and then choose Publish.

    The LightSwitch Publish Application Wizard opens.

  2. On the SharePoint Options page, choose the Autohost option button.

    NoteNote

    This option is the only available option in Microsoft LightSwitch for Visual Studio Update 2.

  3. On the Data Connections page, verify the connection strings for all data sources and update if necessary.

  4. Choose the Finish button.

    When publishing finishes, File Explorer opens to the location of the publishing output. You can now upload the app to your SharePoint site.

Show:
© 2014 Microsoft