动态创建的模板字段 [英] Dynamically Created Template Field

查看:73
本文介绍了动态创建的模板字段的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



任何人都可以阐明如何使用C#在GridView控件中获取动态创建的模板列的ID值和数据.到目前为止,一旦触发回发事件,就无法跟踪动态创建的模板列.

提前谢谢.

Roy

Hi,

Can anybody put some light on how to obtain the ID value and data for Dynamically created template column in a GridView control using C#. As of now the dynamically created template column can not be traced, once a post back event is fired.

Thanks in advance.

Roy

推荐答案

如果您要创建动态模板字段.
您必须先在回发中重新创建它,然后才能在您的代码中使用它...

您可以在创建时设置模板字段的身份ID ...

如果您想更多地了解更多理论,....
转到此链接

http://msdn.microsoft.com/en-us/library/ms972976.aspx [ ^ ]
If u r creating dynamic Template fields..

u must recreate it in post back before using it in ur code...

u can set the attibute ID of Template fields on creation...

If u want to more know more theory....
go for this link

http://msdn.microsoft.com/en-us/library/ms972976.aspx[^]


这篇关于动态创建的模板字段的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆