小编Par*_*ram的帖子

使用CopyIntoItems上传文档时无法更新查找字段

我正在尝试使用Copy.asmx webservice,CopyIntoItems方法从本地计算机上载文档.我可以成功上传文档和DateTime属性,但我无法更新文档库的查找属性.我正在使用带有sp2的MOSS 2007

我使用的代码如下所示:

string[] destinationUrls = { Uri.EscapeUriString(destinationUrl) };

CopySharepointService.FieldInformation dateInformation = new CopySharepointService.FieldInformation();
dateInformation.DisplayName = "Date";
dateInformation.Type = CopySharepointService.FieldType.DateTime;
dateInformation.Value = DateTime.Today.ToString();

CopySharepointService.FieldInformation fundInformation = new CopySharepointService.FieldInformation();
fundInformation.DisplayName = "Fund";
fundInformation.Type = CopySharepointService.FieldType.Lookup;
fundInformation.Id = new Guid(fundGuidItem); // This is the GUID of the field being updated in the document library
fundInformation.Value = "1";

CopySharepointService.FieldInformation[] info = { dateInformation, fundInformation };            
CopySharepointService.CopyResult[] result;    
CopySharepointService.CopySoapClient CopyService2007 = new CopySoapClient("CopySoap");

CopyService2007.ClientCredentials.Windows.ClientCredential = CredentialCache.DefaultNetworkCredentials;
CopyService2007.CopyIntoItems(destinationUrl, destinationUrls, info, fileData, out result);
Run Code Online (Sandbox Code Playgroud)

文档已成功上载,但查找字段未更新 …

web-services sharepoint-2007

5
推荐指数
1
解决办法
3359
查看次数

标签 统计

sharepoint-2007 ×1

web-services ×1