Asp.net 如何使用sharepint 2010中的客户端对象模型在文件中创建签入签出功能
您能告诉我如何使用SharePoint 2010中的客户端对象模型在文档库下的文件中创建签入签出功能吗Asp.net 如何使用sharepint 2010中的客户端对象模型在文件中创建签入签出功能,asp.net,sharepoint-2010,sharepoint-clientobject,Asp.net,Sharepoint 2010,Sharepoint Clientobject,您能告诉我如何使用SharePoint 2010中的客户端对象模型在文档库下的文件中创建签入签出功能吗 感谢kajal每次您在SharePoint文件中创建、删除或更新元数据时 建议您在手术前办理退房手续,手术后办理入住手续 ======================================= //Check Out clientContext = new Microsoft.SharePoint.Client.ClientContext("Your site here"); cl
感谢kajal每次您在SharePoint文件中创建、删除或更新元数据时 建议您在手术前办理退房手续,手术后办理入住手续 =======================================
//Check Out
clientContext = new Microsoft.SharePoint.Client.ClientContext("Your site here");
clientContext.Credentials = new NetworkCredential("LoginID","LoginPW", "LoginDomain");
clientContext.Load(clientContext.Web);
Microsoft.SharePoint.Client.Web web = clientContext.Web;
Microsoft.SharePoint.Client.File f = web.GetFileByServerRelativeUrl("relative path to the file");
f.CheckOut();
clientContext.ExecuteQuery();
//....... Your operation...............
//Check in
clientContext.Credentials = new NetworkCredential("LoginID","LoginPW","LoginDomain");
clientContext.Load(clientContext.Web);
Microsoft.SharePoint.Client.Web web = clientContext.Web;
Microsoft.SharePoint.Client.File f = web.GetFileByServerRelativeUrl("relative path to the file");
f.CheckIn(String.Concat("File CheckingIn at ", DateTime.Now.ToLongDateString()),
Microsoft.SharePoint.Client.CheckinType.MajorCheckIn);
clientContext.ExecuteQuery();
托管客户端对象模型和JavaScript COM中都有签入方法。你到底需要知道什么?到目前为止你做了什么?嗨,谢谢你的回复,我想做文件登记