In a WinForms application, I have a grid component that should draw a triangle on the top corner of the cell on each row based on the values of other columns at the same row.
there is an event called "DrawGridArea", I tried to use it but after drawing the shape, the cell content disappeared.
I used this method for drawing shapes:
e.Graphics.FillPolygon
After a lot of trial and error, I found a solution that works without any problems. The code for this solution is as follows:
To keep the content, I had to use this method:
e.Graphics.DrawString