Ramco Ramco

Ramco Ramco

  • 445
  • 3.4k
  • 530.4k

Color Particular column

Jun 1 2023 6:41 AM

Hi

 i want if colum.segment value = 1 then color of colum.bookid should be blue else color of whole line should be yellow

if (Result != null)
{
    foreach (var colum in Result)
    {
        string StudentName = "";
        View_SessionDetail Res = bALSessionPlan.GetSessionDetail(Convert.ToInt32(colum.SessionPlanID));
        ZoomMeeting Zoom = bALZoom.GetZoomMeetingDetail(Convert.ToInt32(colum.SessionDeliveryCalendarID));

        htmlTable.Append("<tr>");
        htmlTable.Append("<td >" + colum.SessionDeliveryCalendarID + "</td>");
        htmlTable.Append("<td >" + colum.BookID + "</td>");
        htmlTable.Append("<td >" + colum.SessionID + "</td>");
        htmlTable.Append("<td >" + colum.MentorID + "</td>");
        htmlTable.Append("<td >" + colum.Segment + "</td>");
        htmlTable.Append("</tr>");
    }
}

Thanks


Answers (5)