Call to sharepoint web service giving soap error...
I'm trying to build a proof-of-concept project that retrieves forms from a document library. However when I call the GetForm or GetFormCollection method, I get a soap error containing this detail: Guid should contain 32 digits with 4 dashes (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx).
Any insight into what my problem may be is much appreciated.
Thanks in advance.
August 15th, 2007 11:00pm
Can you post a code snip? (You may also want to post to the Development forum.)
Matthew
Free Windows Admin Tool Kit Click here and download it now
August 16th, 2007 2:37pm
when I try to excute the following code
ListService.Lists listService = new ListService.Lists();
listService.Credentials = System.Net.CredentialCache.DefaultCredentials;
listService.Url = "http://localhost:100/sites/DemoCaseTracker/_vti_bin/lists.asmx";
try
{
Label4.Text = listService.AddAttachment("<i>Documents</i>", "CC748623-E7AA-47DB-8A10-5CCDC0649CDA", fileName, contents);
}
catch (System.Web.Services.Protocols.SoapException ex)
where GUID is got using methode "GetListCollection" and is respective to Documents Folder
I am getting the following exception
Message: Exception of type 'Microsoft.SharePoint.SoapServer.SoapServerException' was thrown. Detail: Guid should contain 32 digits with 4 dashes (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx). StackTrace: at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall) at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters) at ListService.Lists.AddAttachment(String listName, String listItemID, String fileName, Byte[] attachment) in c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files
any idea why is this exception occurs?
Thanks In Advance
Regards
Gopi
November 20th, 2007 12:40am
It may be a cut and paste error.
Try browsing to the list settings and look at the query string it should end with something like this: %7B341796DF%2D61C5%2D4917%2D9497%2DA04A6B16032E%7D
Replace the %2d with a dash "-" and remove the beginning %7B and Training %7D and you should be left with "341796DF-61C5-4917-9497-A04A6B16032E" your GUID.
Free Windows Admin Tool Kit Click here and download it now
November 20th, 2007 1:15am
I double checked it, the GUID is correct only
In factIgot this GUID be executing Lists.GetListCollection()
and I checked with your suggestion of trimming and removing%2d etc ..both these guid's are matching
i mean from your method and the guid got from GetListCollection()
But still ending up with same SoapServer Exception??
Thanks
November 20th, 2007 1:48am
Hi All,
Even i have come across the same exception.
Though i have checked with the list GUID & listViewId as per Mathew's previous post but no luck, it continues to throw the same exception "Exception of type 'Microsoft.SharePoint.SoapServer.SoapServerException' was thrown.". and this exception
is thrown exactly at the point where below line code is debugged
XmlNode
ndListView = listService.GetListAndView(ListGUID, viewId);
I have searched over net for almost a day but absolutely no clue..
If anybody has fixed this issue .. Please help me-- its very URGENT.
ThanksTrilochan
Free Windows Admin Tool Kit Click here and download it now
August 20th, 2010 8:38am
The below solution working for me in SharePoint 2010. But I am not sure whether is it a right solution or not. If any one can guide me.
Here is the solution
http://www.fewlines4biju.com/2011/05/exception-of-type-microsoftsharepointso.html
Thanks
Bijay
http://www.fewlines4biju.com
May 5th, 2011 6:19am