Accessing SharePoint 3.0 muliple selection Choice fields using DAO

K

kc

Access 2007 has the Recordset2 and Field2 constructs to handle
multivalued, multiple selection fields and attachments. I'm attempting
to read and write WSS 3.0 multiple selection Choice fields using DAO
and I'm striking out on the correct method/syntax. Has anyone done
this?

Thanks,

Keith.
 
A

Albert D. Kallal

You should be able to go somthing like:


Dim rst As DAO.Recordset
Dim rstChild As DAO.Recordset

Set rst = CurrentDb.OpenRecordset("select * from
LinkedSharePointTable where id = 2")

' now, grab multi-valued child reocrd form the field called FavColors

Set rstChild = rst!FavColors.Value
Do While rstChild.EOF = False
Debug.Print rstChild(0)
rstChild.MoveNext
Loop

The above is air code. You can see how you stuff the ONE field into a new
recordset....

I not tried the above with multi-valued attachments from sharepoint, but the
above is how MV fields are handled in code.
 
K

kc

I tried that technique but rstChield.EOF came back true. rst!FacColors!
Value returns the first selected value if I debug.print it.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top