开发者

Filling in a multi-choice field in a Sharepoint Doc-Lib using SetDocsMetaInfo Frontpage Server Extentions RPC method

开发者 https://www.devze.com 2023-01-07 18:36 出处:网络
I\'ve been given a big chunk of code which eventually calls upon the SetDocsMetaInfo method from Frontpage Server Extension RPC.This is easy enough for most document uploading and property updating, e

I've been given a big chunk of code which eventually calls upon the SetDocsMetaInfo method from Frontpage Server Extension RPC. This is easy enough for most document uploading and property updating, except when dealing with multichoice fields. I've been scouring through MSDN and I can't find anything on how to fill in multiple values for such a field.

The general syntax for properties is something like this: [SR|default], with the type (st开发者_开发知识库ring in this case) followed by a pipe and then the value to be written. Does anyone know the syntax for multichoice fields?

references: MSDN: SetDocsMetaInfo


Did you try separating values with ;# like this: ;#Choice 1;#Choice 2;#

In webservices (Lists.UpdateListItems) that does the trick, perhaps that works in RPC too.


Setting it up like Eric suggested works!!!!

Here is how I setup my hashtable that I use to store my metadata

    Dictionary<string, object> properties = new Dictionary<string, object>(); 
    properties.Add("Title", "Test Title");
    properties.Add("PermitApplicationID", 12);
    //this next line is a metadata field that is a "choice type" field in sharepoint
    properties.Add("DocumentCategories", ";#SP;#FP;#EC;#");
0

精彩评论

暂无评论...
验证码 换一张
取 消