对Dataset操作,可以先输入要显示的字段,然后只查询这一个字段,然后绑定到DataGrid,让DataGrid自动创建列就行了!!

解决方案 »

  1.   

    if you are using SQL Server, try
    1. select col1, col2,..., DATALENGTH(LargeColumn) lc from yourtable2. create template columns for the normal columns col1,col2,...3. in ItemDataBound event handler, create buttons based on the value of lc column4. when the user clicks on the button, create a pop up detail screenfor example, see
    Creating a Details Popup Window Grid in a DataGrid
    http://www.dotnetjunkies.com/tutorials.aspx?tutorialid=505
      

  2.   

    to kinglht(爱新觉罗至尊宝)和brilliant123(brilliant) :你们说的不能解决“只需显示该字段是否有值如果有值则显示一个按钮,点击该按钮查看该字段内容”这个问题。to saucer(思归):我去看看先,下班前结贴。多些各位!还有没有补充的?