0
您好我想在運行時編程調整DataGrid的行高度, 我使用下面的代碼:如何以編程方式更改數據網格控件的行高?
dgRates.DataSource = dsRates.Tables[0];
foreach (DataGridColumnStyle vColumnStyle in dgRates.TableStyles[0].GridColumnStyles)
{
vColumnStyle.Width = 60;
}
但我得到
「ArgumentOutOfRangeException參數 名稱:索引」 。
請告訴我如何解決這個
在此先感謝
Winforms或ASP.NET?這兩個標籤都沒有意義。 – 2011-05-18 09:06:41