1——
DATASET中有多个DATATABLE,现在想创建一个DATAVIEW,这个DATAVIEW是从多个表格通过INNERJOIN来实现的2——
在DATAGRID中,如何设置只编辑某些列?如何设置列的标题名为字段名外的指定字符串?

解决方案 »

  1.   

    1.没做过,不清楚。学习...2.很简单:myDataGrid.Columns[0].HeaderText = "xxxxx";
      也可以使用模版列来设置
      

  2.   

    2>>>你可以把需要编辑的设置成模版列
    ,AutoGenerateColumns设置为False 用属性生成器,直接写页眉标题
      

  3.   

    1. you have to create a separate datatable for it, for example, seeHOW TO: Implement a DataSet JOIN helper class in Visual C# .NET
    http://support.microsoft.com/default.aspx?scid=kb;EN-US;3260802. assume you are talking about the datagrid in winform>>>在DATAGRID中,如何设置只编辑某些列?look into DataGridColumnStyle.ReadOnlyhttp://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/html/frlrfsystemwindowsformsdatagridcolumnstyleclassreadonlytopic.asp>>>>如何设置列的标题名为字段名外的指定字符串?look into DataGridColumnStyle.HeaderTexthttp://msdn.microsoft.com/library/en-us/cpref/html/frlrfSystemWindowsFormsDataGridColumnStyleClassHeaderTextTopic.asp?frame=truealso see
    Tailor Your DataGrid Apps Using Table Style and Custom Column Style Objects
    http://msdn.microsoft.com/msdnmag/issues/03/08/DataGrids/default.aspx
      

  4.   

    如果是Web程序的话,你看看DataGrid的属性生成器!
      

  5.   

    2——
    在DATAGRID中,如何设置只编辑某些列?如何设置列的标题名为字段名外的指定字符串?自己可以在程序中控制数据库的ID
      

  6.   

    非常感谢死鬼!发了这个帖子后简单看了下SDK文档,只是太困了,又要上班,所以没有实验了。