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.
- 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
- Complete the “Web services and the Business Connectivity Services in SharePoint 2010” Tutorial
- You should have the following External Content Type on your Diagram
- From the “BCS Meta Man Data Source Explorer” drag and drop your Creator Web Method onto the WebServiceCustomer External Content Type.
- Select “Creator” as the “Method Type” and click “OK”
- Our Creator Method has been added
- Next drag and drop your Updater Web Method onto the “WebServiceCustomer” External Content Type
- Select “Updater” as the “Method Type” and click “OK”
- The complete External Content Type will look like the following
- Press F5 to deploy, this will load up your SharePoint Page once deployed
- Next we need to create an External List
- While viewing your SharePoint site through the browser, click on “Site Actions” –> “More Options…”
- From the list of items to create select “External List” and click the “Create” button
- 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
- 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
- You will be presented with the editing dialog
- This will save the changes through Web Service directly back to your external data system that the external content type is hooked up to.
- While viewing the external list, if you cli
ck the Items tab on the ribbon you’ll see a New Item button - This will bring up the “New Item” dialog where you can add a new customer and click “Save” then.
- The updated external data provided by web service is now displayed in the SharePoint External List
We hope this walkthrough will be useful for you. If you have any questions feel free to email them to support@lightningtools.com