【问题标题】:Telerik RadGrid GridTemplateColumns programmaticallyTelerik RadGrid GridTemplateColumns 以编程方式
【发布时间】:2012-07-19 14:40:39
【问题描述】:

我需要制作多个带有可编辑列的 RadGrid。我了解如何制作绑定列和制作模板列,但我不知道如何将文本框和下拉列表放置在这些模板列中。

string templateColumnName = "ContactName";
GridTemplateColumn templateColumn = new GridTemplateColumn();
templateColumn.ItemTemplate = new MyTemplate(templateColumnName);
templateColumn.HeaderText = templateColumnName;

之后我该怎么办。

【问题讨论】:

    标签: telerik radgrid


    【解决方案1】:

    您应该在容器中实例化所需的 web 控件。这发生在 InstantiateIn 方法中。我建议您检查此链接: Programmatic creation

    如果您需要更多信息,也可以查看以下信息: Creating Web Server Control Templates Programmatically

    如果您对此有任何具体问题,请告诉我们。

    【讨论】:

      猜你喜欢
      • 2011-12-23
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2012-03-31
      • 1970-01-01
      相关资源
      最近更新 更多