Results 1 to 2 of 2

Thread: [2008] customizing datagridview

  1. #1

    Thread Starter
    Hyperactive Member shyguyjeff's Avatar
    Join Date
    Jul 2007
    Location
    City of Durian
    Posts
    289

    [2008] customizing datagridview

    Hello everyone, It's me again. Could anyone help me to solve my problem? Its all about customizing datagridview. Here it goes, I have a 10 columns datagrid view the first column,I want the text to be aligned left and the rest of the rows are aligned right is it possible? How this can be done? My second problem is all about coloring the columns. I want that the first column will be color yellow and the the rest are black. HOw can I do that? Thanks everyone. God BLess!
    Last edited by shyguyjeff; Sep 21st, 2008 at 08:35 PM.

  2. #2
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,222

    Re: [2008] customizing datagrid

    1. Is this really a DataGrid or is it a DataGridView?

    2a. If it's a DataGridView then please use the proper names for things in future so we don't waste our time providing irrelevant advice. Formatting a DataGrid is quite different to formatting a DataGridView.

    2b. If it's a DataGrid, is there a particular reason you're using the less-functional DataGrid in preference to the more-functional DataGridView.

    3. If it's a DataGridView then each column has it's own properties for formatting. If you're not sure which do what then the MSDN documentation would be the first place to look. The DefaultCellStyle would be a goo one to start with as I think that includes alignment properties but, as I said, MSDN can tell you for sure.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width