0
我试图通过使用C#中的动态表来显示时隙列表。但是,它不能正常工作。下面是我的结果: 使用动态表来显示字符串列表
这里是我的代码
List<AvailableTime> AllTimeSlots = RequestDirector.ListAllAvailableTimes(BookingDate);
foreach (AvailableTime resultTimeslot in AllTimeSlots)
{
TableRow TimeSLotRow = new TableRow();
TableCell TimeSlotCell = new TableCell();
TimeSlotCell.Text = Convert.ToString(resultTimeslot.TimeSlot);
TimeSLotRow.Cells.Add(TimeSlotCell);
Table1.Rows.Add(TimeSLotRow);
}
我想显示5个时隙的每一行。任何人都可以告诉我我该怎么做?
它完美。谢谢你的帮助。 – GKra