Last post Oct 19, 2018 04:32 PM by avt2k7
Oct 19, 2018 02:03 PM|avt2k7|LINK
I want to display my subject values based on whether or not exist the data. I am not sure how to comma delimited for my specific data layout as follows:
@if (ViewBag.SearchSubjects != null)
@if (item.HasEnglish == true)
@if (item.HasMath == true)
@if (item.HasScience == true)
@if (item.HasSocialStudy == true)
@: SOCIAL STUDY,
For example: my sample data result can be ENGLISH, MATH, SCIENCE or MATH, SOCIAL STUDY or SCIENCE, MATH, SOCIAL STUDY, ENGLIGH etc.
I really apreciate your help. Thanks in advance.
Oct 19, 2018 04:32 PM|avt2k7|LINK
I used string builder and trim(), TrimEnd() to concatenate string for resolve comma delimited issue. Thanks.