I wrote a loop to display each line one by one from a list of lines. The problem is that the list contains more than 45,000 lines, and it takes a long time to create a page to display.
Can anyone help in optimizing the code!
List<string> OverrrideLog = lc.getOverrideLog(); List<string> AccessLog = lc.getAccessLog(); foreach (string s in OverrrideLog) lblOverrideLog.Text += s + "<br/>"; foreach (string s in AccessLog) lblAccessLog.Text += s + "<br/>";
Here lblOverrideLog and lblAccessLog are literals, and each list contains more than 22,000 lines.
source share