Adjust the datagrid column with in edit mode
void MyGrid_Edit(object sender, DataGridCommandEventArgs e) {
MyGrid.EditItemIndex = e.Item.ItemIndex;
BindMyGrid();
DataGridItem line = MyGrid.Items[e.Item.ItemIndex];
TextBox tb1 = (TextBox)line.Cells[0].Controls[0];
TextBox tb2 = (TextBox)line.Cells[1].Controls[0];
tb1.Width = Unit.Percentage(100);
tb2.Width = Unit.Percentage(100);
tb2.TextMode = TextBoxMode.MultiLine;
}
refer: http://www.atmarkit.co.jp/fdotnet/dotnettips/082wideedit/wideedit.html
Posted
Apr 23 2004, 07:18 AM
by
Montaque