Exercise 3: Test the Silverlight Application in SharePoint Online

Task 1 – Update Service Reference

Before packaging up the solution and deploying it to SharePoint Online, you need to update the service reference to the SharePoint Lists web service and repackage the solution.

  1. In the Solution Explorer window, open the AddTimeEntryWS project.
  2. Expand the Service References node.
  3. Right-click the SPListsWebService service reference, and select Configure Service Reference.
  4. In the Address textbox, change the URL to the SharePoint Lists web service in the SharePoint Online site you created for this lab, e.g., https://contoso.sharepoint.com/Lab04/_vti_bin/lists.asmx.

    Note:
    You might be prompted to authenticate to your SharePoint Online site. Enter the credentials that you use to access your SharePoint Online site.
  5. Click OK to close the Service Reference Settings dialog.
  6. Right-click the SPListsWebService service reference, and select Update Service Reference.
  7. The reference to the SharePoint Lists web service will be updated to point to the web service in your SharePoint Online site.

Task 2 – Deploy the Lab Solution to SharePoint Online

In this task, you will deploy the solution package to SharePoint online to confirm that it works as expected.

  1. In the Solution Explorer, right-click on AddTimeEntry and select Package to package the project.
  2. Open Internet Explorer and navigate to your SharePoint Online site.
  3. Click Site Actions and then select Site Settings.

  4. Click the Solutions link in the Galleries section to view the site collection’s solution gallery.

  5. Click on the Solutions tab in the ribbon and click the Upload Solution button.

  6. Browse to C:\%Office365TrainingKit%\Source\Labs\4.3\Source\Before\AddTimeEntry\bin\Debug\AddTimeEntry.wsp and click Open.
  7. Click the Activate button.
  8. Browse to the site you created for this lab, e.g., https://contoso.sharepoint.com/Lab04.
  9. Click Site Actions>> Site Settings and choose Manage Site Features.
  10. Click the Activate button next to the AddTimeEntry Feature1 feature to activate the feature and deploy the Silverlight application and ASPX page.
  11. Navigate to the <Site>/SitePages/AddTimeEntryWS.aspx to view the custom page with the Silverlight application.
  12. Enter the following values in the Silverlight application:
    • Task: Create Intranet Portal
    • Employee: Neil Orint
    • Date: Enter today’s date
    • Hours: 2
    • Description: Created site wireframe diagram.

  13. Click Save.

    A popup window will appear to let you know the time entry was saved.

  14. Click OK.
  15. Click the Billable Time link to view the list.

  16. Verify that the new entry is in the list.

  17. Close Internet Explorer.