0

In C# Windows Application DataGridView, the value of a cell is a text with more than 40 characters. The characters are not showing when the column size is less. If the column size is increased, then other column values got disturbed. So I want a solution that, the cell value with more characters overlap or display in the next cell(ie.next column). (Like in Excel)

I already tried Wrap mode and autosizecolumnsmode.

I expect an output shown below like excel
(source: fordevs.com)

Glorfindel
  • 21,988
  • 13
  • 81
  • 109
  • 1
    The picture shows a feature of Excel. If there was text in cell B1, the text in cell A1 would be cut off also. The `DataGridView` does not have this property/feature as far as I know. I am confident you will have to implement this yourself or look for a third-party grid. – JohnG Jan 22 '19 at 06:45
  • You can get rid of cell borders but you can't merge cells or make one display overlapping content. So the content will always be either in one cell or be split in the middle. – TaW Jan 22 '19 at 07:57
  • You can manually draw cells. See https://stackoverflow.com/q/16774966/5045688 – Alexander Petrov Jan 22 '19 at 10:01

1 Answers1

0

You can use a custom implementation using

Canvas.SetZIndex(item,index);
ousspero
  • 19
  • 4