Results 1 to 7 of 7

Thread: combobox in datagrid

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Jun 2007
    Posts
    403

    combobox in datagrid

    can anyone show me how to put a combobox in a datagrid?

    thanks...

    VB Version: Microsoft Visual Studio 2008 Professional Edition
    .NET Version: Microsoft .NET Framework Version 3.5
    OS: Windows XP SP3

  2. #2
    Member apolizoi's Avatar
    Join Date
    Jan 2005
    Location
    Greece
    Posts
    44

    Re: combobox in datagrid

    For VS 2005 I hope this will help you :

    http://msdn2.microsoft.com/en-us/library/bxt3k60s.aspx

  3. #3

    Thread Starter
    Hyperactive Member
    Join Date
    Jun 2007
    Posts
    403

    Re: combobox in datagrid

    Quote Originally Posted by apolizoi
    For VS 2005 I hope this will help you :

    http://msdn2.microsoft.com/en-us/library/bxt3k60s.aspx
    unfortunately im using VS 2003.

    any ideas on how to do it on VS 2003?

    VB Version: Microsoft Visual Studio 2008 Professional Edition
    .NET Version: Microsoft .NET Framework Version 3.5
    OS: Windows XP SP3

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

    Re: combobox in datagrid

    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

  5. #5

    Thread Starter
    Hyperactive Member
    Join Date
    Jun 2007
    Posts
    403

    Re: combobox in datagrid

    Quote Originally Posted by jmcilhinney
    thanks! this link was very helpful.

    althought i have a question regarding 5.84 since the link to the VB code was dead.

    it says here that instead of using a datagrid i.e having 3 columns (ex:. name, address, email), i can use like for ex: 9 textboxes (3 columns, 3 rows) to display my datatable? is this true?

    VB Version: Microsoft Visual Studio 2008 Professional Edition
    .NET Version: Microsoft .NET Framework Version 3.5
    OS: Windows XP SP3

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

    Re: combobox in datagrid

    You can use whatever controls you think appropriate. A grid is a convenient way to display tabular data with an unknown number of rows. If you want to display it some other way that's up to you.
    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

  7. #7

    Thread Starter
    Hyperactive Member
    Join Date
    Jun 2007
    Posts
    403

    Re: combobox in datagrid

    the thing is im worried about navigation of rows if for example i used a set of textboxes... like the example i used earlier... 9 textboxes (3 rows and 3 columns)... if in case my data tables contains more than 3 records/rows, then the textboxes i have will display the first 3 records/rows then i can use a scroll bar to scroll down to the remaining records.. is this possible?

    the reason why im asking is because this way might be an easier way to handle triggers/events since i will be using the textboxes events instead of finding a way to create an OnCellLeave event or something like that.

    VB Version: Microsoft Visual Studio 2008 Professional Edition
    .NET Version: Microsoft .NET Framework Version 3.5
    OS: Windows XP SP3

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