Is there a way to store the array in a custom MOSS content type?

I need to store an array in a custom content type in MOSS. It will always be hidden, used only programmatically. Throughout the lifecycle of a list item, I will add values ​​to the array. My array might look like this:

value1,1 | value1,2 | value1,3 | value1,4
value2,1 | value2,2 | value2,3 |
value3,1 | value3,2 | value3,3 |
value4,1 | value4,2 | value4,3 | value4,4

I know that I can use SPFieldMultiColumn to store the first row, but it doesn't seem like I can store multiple rows. I also know I can just create a textbox and serialize my array myself. Just curious if there is still a field to use when you need to store the array.

+1


source to share


2 answers


There is no field where you can store a 2D array.
Typically, you either store each line in a different element, or serialize your value in a simpler field (like multiline text).



+3


source


Serialization is probably your best solution for small arrays. Or you can keep it in a separate list. And remember, there is no law against creating your own spreadsheet.



+1


source







All Articles