Solved

C# VS 2005 DataGridView column width

Posted on 2006-06-13
1
519 Views
Last Modified: 2012-06-21
I am binding a select statements results which is stored into a Datatable to the DataGridView control.

The data is all there but I need to make it look better.

How do I get the Headers to autofill the entire width of the DataGridView and can I get rid of the column of boxes on the far left?
0
Comment
Question by:Rowdyone52
1 Comment
 
LVL 12

Accepted Solution

by:
topdog770 earned 500 total points
Comment Utility
<< How do I get the Headers to autofill the entire width of the DataGridView >>
The datagridview will have a collection of columns.   Each column has a AutoSizeMode property, setting this property to Fill will cause that specific column to fill in the 'blank' portion of the datagridview.

<< can I get rid of the column of boxes on the far left? >>

Setting your DataGridView('s).RowHeadersVisible = false will cause the column of boxes on the far left ( the row headers) to no longer show.
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

This article describes a simple method to resize a control at runtime.  It includes ready-to-use source code and a complete sample demonstration application.  We'll also talk about C# Extension Methods. Introduction In one of my applications…
Entity Framework is a powerful tool to help you interact with the DataBase but still doesn't help much when we have a Stored Procedure that returns more than one resultset. The solution takes some of out-of-the-box thinking; read on!
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now