0

i created a UserMulti field inside my list's instance. Heres how i declared it.

  <Row>
    <Field Name ="Title">List1</Field>
    <Field Name ="aatMessage">Message place holder</Field>
    <Field Name ="aatStartDate">2012-03-01T09:39:44Z</Field>
    <Field Name ="aatEndDate">2012-03-31T09:39:46Z</Field>
    <Field Name ="aatColleague">DTM01\Mathieu.Landry</Field>
  </Row>

The problem i have is filling up the "aatColleague" field. Adding my user doesnt seem to work. I tried without the DTM01 and it still doesnt work. Also since i added this, the item doesnt show in the list anymore but if i remove the aatColleague field it all works.

2

I have not tested this but try

<Field Name ="aatColleague">-1;#Mathieu.Landry</Field>
  • Would you need to know the Sharepoint user id from the site's user list and have 1#;Mathieu.Landry ? – Ian Mar 12 '12 at 20:53
  • See my edited response. I just verified it via powershell. You do not need the id from userinfo list. Set the id to -1 – sssreddy Mar 12 '12 at 21:16
  • Worked. Sorry for taking so long. – Dr.Denis McCracleJizz Mar 20 '12 at 17:57
0

You could always add the data in a feature activated event receiver ? This is a lot more flexible and you can debug it too.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.