Add to List from codebehind C# Asp.net

后端 未结 5 1113
春和景丽
春和景丽 2020-12-09 03:10

I have a UL list in a ASPX page:

  • Tab 1
5条回答
  •  失恋的感觉
    2020-12-09 03:32

    This result is the same as GenericTypeTea's, but the difference is the HTML is 'written' in the code behind and injected into the page.

    In your markup:

    
    

    In your code behind:

    List locations  // however this initialized 
    
    StringBuilder sb = new StringBuilder();
    
    sb.Append("");
    
    litMarkup.Text = sb.ToString();
    

提交回复
热议问题