Results 1 to 3 of 3

Thread: Populating data in a dataGridView

  1. #1

    Thread Starter
    Member
    Join Date
    Jan 2010
    Posts
    45

    Populating data in a dataGridView

    I have made a list of the objects that I need on the datagridview but how do I display my list items onto the grid?

    How can I make each of my list items populate on an individual rows?

  2. #2
    eXtreme Programmer .paul.'s Avatar
    Join Date
    May 2007
    Location
    Chelmsford UK
    Posts
    26,424

    Re: Populating data in a dataGridView

    can you post the code you use to make your list of objects?

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

    Re: Populating data in a dataGridView

    If you have your objects in an array, ArrayList, generic List or the like then you can simply assign that to the grid's DataSource property. You may need to do a little more though, depending on exactly what you want to achieve and exactly how you object type and the list type are implemented.
    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