different kinds of cells in the same column

…衆ロ難τιáo~ 提交于 2020-01-17 11:12:06

问题


I need to render a datagrid with different kinds of cells in the same column. For example, I have a datagrid with a column "name" and a column "value". Depending on the "type" of my record, I would have different cells in the column "value" like a combobox or a simple textfield. and I don't really see how to do that programmatically... I don't know if the datagrid is the best choice. Any hint?

I'm using asp.net/vb.net with framework 3.5


回答1:


You can do that using the user control, where you pass the "type" to the user control and the user control will handle the type of control to show or generate.



来源:https://stackoverflow.com/questions/7496470/different-kinds-of-cells-in-the-same-column

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!