Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DataGrid: How to hide very first row selection column 1

Status
Not open for further replies.

towguy

Programmer
Jun 22, 2006
9
I am unable to find a way to hide very first row selection column in DataGrid. I only want to display actual data rows, not any headers.
Thanks
 
In the properties window for the datagrid you should see a property called ColumnHeadersVisible. Set this property to False, either in the properties window or in code with something like DataGrid1.ColumnHeadersVisible = False.



I used to rock and roll every night and party every day. Then it was every other day. Now I'm lucky if I can find 30 minutes a week in which to get funky. - Homer Simpson

Arrrr, mateys! Ye needs ta be preparin' yerselves fer Talk Like a Pirate Day! Ye has a choice: talk like a pira
 
Thanks jebenson
yes I have tried same property. But It work when grid add columns automaticaly. after adding tablestyle it does not work.
 
The DataGridTableStyle also has the ColumnHeadersVisible property. Setting it to False should work:

Dim ts As DataGridTableStyle

ts.ColumnHeadersVisible = False



I used to rock and roll every night and party every day. Then it was every other day. Now I'm lucky if I can find 30 minutes a week in which to get funky. - Homer Simpson

Arrrr, mateys! Ye needs ta be preparin' yerselves fer Talk Like a Pirate Day! Ye has a choice: talk like a pira
 
Yes ColumnHeadersVisible is working.
Thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top