0
任何人都可以告訴我如何調用SharePoint Web服務GetListItems
。我在調用此方法如何使用目標C調用Sharepoint Web服務GetListItems C
的代碼爲我的HTTP頭請求收到錯誤消息「403禁止」是:
[theRequest setValue: cookie forHTTPHeaderField:@"Cookie"];
[theRequest setHTTPShouldHandleCookies:YES];
[theRequest addValue: @"text/xml; charset=utf-8" forHTTPHeaderField:@"Content-Type"];
[theRequest addValue: saction forHTTPHeaderField:@"SOAPAction"];
[theRequest addValue: msgLength forHTTPHeaderField:@"Content-Length"];
[theRequest setHTTPMethod:@"POST"];
[theRequest setHTTPBody: [soapMessage dataUsingEncoding:NSUTF8StringEncoding]];
urlconnection = [NSURLConnection connectionWithRequest:theRequest delegate:self];
我對調用GetListItems
方法XML結構爲:
<listName>listName</listName><viewName></viewName>< Query />< ViewFields />< rowLimit>< /rowLimit>< QueryOptions>< IncludeAttachmentUrls>TRUE< /IncludeAttachmentUrls>< /QueryOptions>< webID>< /webID>< /GetListItems>< /soap:Body>< /soap:Envelope>
有人可以告訴我我錯了什麼或者我需要做什麼嗎?
在此先感謝。
嗨, 你怎麼會解決這個問題? – 2011-05-16 16:14:13