Creating\Updating list items in subsite via Sharepoint webservices
If you ever want to add or update a list item in your subsite using SharePoint's Lists.asmx webservice you would notice that that even after registering the subsite's lists.asmx url you would end up updating the item on the parent site instead.
To solve this issue simply set the webservice url in your code to point to the subsite url(see below)
ListService.Credentials = System.Net.CredentialCache.DefaultCredentials;
ListService.Url = "https://SPParentSite/subsite/_vti_bin/Lists.asmx";
simple isn't it.
To solve this issue simply set the webservice url in your code to point to the subsite url(see below)
ListService.Credentials = System.Net.CredentialCache.DefaultCredentials;
ListService.Url = "https://SPParentSite/subsite/_vti_bin/Lists.asmx";
simple isn't it.
0 comments:
Post a Comment