Results 1 to 3 of 3

Thread: Dbcombo Help Needed

  1. #1

    Thread Starter
    Addicted Member CoMMiE's Avatar
    Join Date
    Jul 2000
    Location
    Malaysia, Kuala Lumpur
    Posts
    179
    Hi
    Code:
    Private Sub DBCombo1_Change()
    
    Data2.RecordSource = "select * from CustomerPriceList where productcodeno='" & Trim(DBCombo1.Text) & "'"
    
    Data2.Refresh
    The above codes work perfectly but the problem is when the user select a item inside the combobox the list of productcodeno inside the combobox will be gone

    My question is how can i maintain the list of productcodeno inside the combobox when the SQL statement is executed?

    I would be gratefull if anyone out here can help out
    Thanks in advance!!

  2. #2
    Lively Member
    Join Date
    Aug 2000
    Posts
    125
    use another data control (other than data2) to populate the combobox

    an example at:
    http://pages.about.com/vbmakai/dao2.htm

  3. #3

    Thread Starter
    Addicted Member CoMMiE's Avatar
    Join Date
    Jul 2000
    Location
    Malaysia, Kuala Lumpur
    Posts
    179

    Thumbs up

    Thanks a lot makai !!!
    I tried your suggestion and it works perfectly

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