I have a dataGridView1. In a datagrid you can manually write columnheader names.
(Each Column can have a name)
What I wonder is how it is possible to programatically write a name for example column Numer 1 ?
I have looked at the memeber of the class but cant really find /understand wich of these that could be used.

dataGridView1-> ?

The Columns property gives you access to individual column attributes:

dataGridView1->Columns[0]->Name = "Ed's Column";

I did change Name to HeaderText and this did work.
Thanks...

dataGridView1->Columns[0]->HeaderText = "Ed's Column";

The Columns property gives you access to individual column attributes:

dataGridView1->Columns[0]->Name = "Ed's Column";
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.