Results 1 to 3 of 3

Thread: [RESOLVED] Selecting value using combobox

Threaded View

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Jul 2006
    Posts
    135

    [RESOLVED] Selecting value using combobox

    Hi All,

    is it possible for me to select an additional value from my datatable when selecting a value in a combobox?

    I have a sql query:

    SELECT KeyCol, Col2, Col3 FROM TestTable

    I bind the combo like so:

    cboTest.DataSource = dtTest
    cboTest.DisplayMember = "Col2"
    cboTest.SelectedItem = "KeyCol"
    cboTest.ValueMember = "KeyCol"

    Now what I would like to do is get the value of "Col3" when the user fires the selectedindex_changed event.

    Hope this is clear, any help appreciated.
    Last edited by CodeKiller; Apr 4th, 2007 at 07:45 AM.
    ---------------------------------------------------
    VB 2003
    SQL Server 2000

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