Autor Beitrag
Questioneer
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 32



BeitragVerfasst: Di 28.10.08 15:35 
Hi,

ich möchte die Columns meines DGV auf NotSortable setzen:

ausblenden C#-Quelltext
1:
2:
3:
4:
5:
6:
           DataGridViewTextBoxColumn filterCol = new DataGridViewTextBoxColumn();
            for (int i = 1; i <= iGridWidth;  i++)
            {           
                dgBmpDaten.Columns.Add((i.ToString()) , (i.ToString()));
                filterCol.SortMode = DataGridViewColumnSortMode.NotSortable;
            }


Es kommt zwar keine Fehlermeldung aber die Eigenschaft wird nicht übernommen, die Spalten sind weiterhin sortierbar !


Könnt Ihr mir sagen wie ich das zum funzen bringe ?

Vielen dank für eure Hilfe und Mühe
Questioneer
Th69
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Moderator
Beiträge: 4807
Erhaltene Danke: 1061

Win10
C#, C++ (VS 2017/19/22)
BeitragVerfasst: Di 28.10.08 15:55 
Überleg mal, auf welches Objekt du die Eigenschaft 'SortMode' anwendest.
Questioneer Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 32



BeitragVerfasst: Di 28.10.08 15:56 
Oh Mann, Danke klappt !!!!!!!!!!

Gruß
Questioneer