I have a custom checkboxlist datatype where I have entered pre-values with valid professions. A, B and C
When I output people's professions in a comma-separated list like this:
@employee.professions.Replace(",", ", ")
I get "A, B, C" because all three are checked.
Then I move C between A and B on the datatype, but I still get "A, B, C".
It looks like the selected values are written in the order they were created in the database, re-ordering the options in the datatype editor doesn't change anything in the output. Is there anything I can do to see and use the sortorder, or manually do an "OrderBy" when I output values?
Second, I might want to output selected values alphabetically - is that possible? Independent of the sortorder used internally in Umbraco.
Prevalues sortorder not reflected on output
Hi
I have a custom checkboxlist datatype where I have entered pre-values with valid professions. A, B and C
When I output people's professions in a comma-separated list like this:
@employee.professions.Replace(",", ", ")
Then I move C between A and B on the datatype, but I still get "A, B, C".
It looks like the selected values are written in the order they were created in the database, re-ordering the options in the datatype editor doesn't change anything in the output. Is there anything I can do to see and use the sortorder, or manually do an "OrderBy" when I output values?
Second, I might want to output selected values alphabetically - is that possible? Independent of the sortorder used internally in Umbraco.
BR, Jan
is working on a reply...