C# DataGrid Question
-
I want to add a new line to one of the Datagrid Column Value. How do i do it Suppose i have Mike and Bond and i want Mike and Bond in different lines but in the same column. Thanks Kal
-
I want to add a new line to one of the Datagrid Column Value. How do i do it Suppose i have Mike and Bond and i want Mike and Bond in different lines but in the same column. Thanks Kal
Hello Correct me if I'm wrong, but I don't think it's possible. Regards:rose:
-
Hello Correct me if I'm wrong, but I don't think it's possible. Regards:rose:
You can set DefaultCellStyle.WrapMode = DataGridViewTriState.True. So, you can enter value to cell as "Mike" + Environment.NewLine + "Bond". BUT, in this case if some other cell width is small its value will be wrapped as well. To avoid this you can leave DefaultCellStyle in its default value and set individual cell's style only.
Vitaliy Tsvayer Tikle