Creator and Updater BCS Methods in SharePoint 2010 using Web Service

 BCS Meta Man, SharePoint 2010.

In this tutorial we will show you how to use Web Service to add the data using an External List and also to Update and existing data using BCS Meta Man.

We are going to follow on from the “Web services and the Business Connectivity Services in SharePoint 2010” walkthrough.

  1. Prerequisites:
    • Microsoft SharePoint Server 2010
    • Microsoft Visual Studio 2010 Professional or higher
    • BCS Meta Man
    • Web Service with Finder, Specific Finder, ID Enumerator, Creator and Updater web methods
  2. Complete the “Web services and the Business Connectivity Services in SharePoint 2010” Tutorial
  3. You should have the following External Content Type on your Diagram

    External Content Type with with Finder, Specific Finder, ID Enumerator methods

  4. From the “BCS Meta Man Data Source Explorer” drag and drop your Creator Web Method onto the WebServiceCustomer External Content Type.

    Drag and drop Creator Web Method onto existing External Content Type

  5. Select “Creator” as the “Method Type” and click “OK”

    Configuring Creator web method

  6. Our Creator Method has been added

    External Content Type with with Finder, Specific Finder, ID Enumerator, Creator methods

  7. Next drag and drop your Updater Web Method onto the “WebServiceCustomer” External Content Type
  8. Select “Updater” as the “Method Type” and click “OK”
  9. The complete External Content Type will look like the following

    External Content Type with with Finder, Specific Finder, ID Enumerator, Creator and Updater methods

  10. Press F5 to deploy, this will load up your SharePoint Page once deployed
  11. Next we need to create an External List
  12. While viewing your SharePoint site through the browser, click on “Site Actions” –> “More Options…”
  13. From the list of items to create select “External List” and click the “Create” button
  14. In the configuration screen that opens up, give your External List a name and use the External Content Type picker to select the External Content Type we have just deployed to SharePoint. Click “Create” then

    Create an External List

  15. You can hover over the first column of your list and you’ll see a drop down appear. If you click the drop down arrow you’ll get a number of options for that particular row of data – one of which will be Edit Item

    Edit items through External List

  16. You will be presented with the editing dialog

    Edit Item dialog

  17. This will save the changes through Web Service directly back to your external data system that the external content type is hooked up to.
  18. While viewing the external list, if you cli
    ck the Items tab on the ribbon you’ll see a New Item button

    Add new data through External List

  19. This will bring up the “New Item” dialog where you can add a new customer and click “Save” then.

    New Item Dialog

  20. The updated external data provided by web service is now displayed in the SharePoint External List

    Updated External data provided by web service is now shown within SharePoint 2010

We hope this walkthrough will be useful for you. If you have any questions feel free to email them to support@lightningtools.com

Leave a Reply

Your email address will not be published. Required fields are marked *

*

HTML tags are not allowed.