Try this:
SPFieldMultiChoiceValue x;
for (int i = 0; i < x.Count; i++)
{
string z = x[i];
}
________________________________
From: [EMAIL PROTECTED] [EMAIL PROTECTED] On Behalf Of Chris Grist [EMAIL
PROTECTED]
Sent: Wednesday, 3 September 2008 11:01 AM
To: [email protected]
Subject: [OzMOSS] RE: programming accessing checkboxes
Thanks,
That one doesn’t seem to work, doesn’t compile the for each saying that
spfieldmultichoicevalue isn’t a collection
Chris Grist
Network Support Officer
education.au Limited
Level 1, 182 Fullarton Road
DULWICH SA 5065
p +61 8 83343291
f +61 8 83343211
e [EMAIL PROTECTED]<mailto:[EMAIL PROTECTED]>
w www.educationau.edu.au<http://www.educationau.edu.au/>
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Sezai KOMUR
Sent: Wednesday, September 03, 2008 12:03 PM
To: [email protected]
Subject: [OzMOSS] RE: programming accessing checkboxes
It returns object by default and so you need to cast it to
SPFieldMultiChoiceValue or pass the value string in as a constructor to a new
SPFieldMultiChoiceValue object.
http://sharepointcodeblock.blogspot.com/2008/07/properly-populating-and-retrieving.html
SPFieldMultiChoiceValue itemValue = new
SPFieldMultiChoiceValue(item["FieldName"].ToString());
foreach (string choice in itemValue)
{
// value is in choice
}
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Tommy Segoro
Sent: Wednesday, 3 September 2008 10:29 AM
To: [email protected]
Subject: [OzMOSS] RE: programming accessing checkboxes
Isn't it returning SPFieldMultiChoiceValue object? It's a collection so you
should be able to do foreach on that object and it wil return the selected
values.
________________________________
From: [EMAIL PROTECTED] [EMAIL PROTECTED] On Behalf Of Chris Grist [EMAIL
PROTECTED]
Sent: Wednesday, 3 September 2008 10:14 AM
To: [email protected]
Subject: [OzMOSS] programming accessing checkboxes
Hi Guys,
I want to access a column.
i.e. item[“test”]
This column is a checkbox column with several checkboxes each with its own name
like Monday,Tuesday,All etc.
Im wanting to know which checkboxes are checked.
Whats the method of doing this?
Chris Grist
Network Support Officer
education.au Limited
Level 1, 182 Fullarton Road
DULWICH SA 5065
p +61 8 83343291
f +61 8 83343211
e [EMAIL PROTECTED]<mailto:[EMAIL PROTECTED]>
w www.educationau.edu.au<http://www.educationau.edu.au/>
________________________________
IMPORTANT: This e-mail, including any attachments, may contain private or
confidential information. If you think you may not be the intended recipient,
or if you have received this e-mail in error, please contact the sender
immediately and delete all copies of this e-mail. If you are not the intended
recipient, you must not reproduce any part of this e-mail or disclose its
contents to any other party. This email represents the views of the individual
sender, which do not necessarily reflect those of Education.au except where the
sender expressly states otherwise. It is your responsibility to scan this email
and any files transmitted with it for viruses or any other defects.
education.au limited will not be liable for any loss, damage or consequence
caused directly or indirectly by this email.
------------------------------------------------------------------- OzMOSS.com
- to unsubscribe from this list, send a message back to the list with
'unsubscribe' as the subject.
Powered by mailenable.com
------------------------------------------------------------------- OzMOSS.com
- to unsubscribe from this list, send a message back to the list with
'unsubscribe' as the subject.
Powered by mailenable.com
------------------------------------------------------------------- OzMOSS.com
- to unsubscribe from this list, send a message back to the list with
'unsubscribe' as the subject.
Powered by mailenable.com
________________________________
IMPORTANT: This e-mail, including any attachments, may contain private or
confidential information. If you think you may not be the intended recipient,
or if you have received this e-mail in error, please contact the sender
immediately and delete all copies of this e-mail. If you are not the intended
recipient, you must not reproduce any part of this e-mail or disclose its
contents to any other party. This email represents the views of the individual
sender, which do not necessarily reflect those of Education.au except where the
sender expressly states otherwise. It is your responsibility to scan this email
and any files transmitted with it for viruses or any other defects.
education.au limited will not be liable for any loss, damage or consequence
caused directly or indirectly by this email.
------------------------------------------------------------------- OzMOSS.com
- to unsubscribe from this list, send a message back to the list with
'unsubscribe' as the subject.
Powered by mailenable.com
------------------------------------------------------------------- OzMOSS.com
- to unsubscribe from this list, send a message back to the list with
'unsubscribe' as the subject.
Powered by mailenable.com