CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4
  1. #1
    Join Date
    Jul 2003
    Posts
    12

    Angry Listindex not following

    If cboVille.Text <> "" Then
    VL = cboVille.Text
    postcode = cboCP.Text
    paysnr = cboPays.ItemData(cboPays.ListIndex)

    Set rsCVille = databank.OpenRecordset("Select * from tblPostcodes where Pays like '" & paysnr & "' and PCode like '" & postcode & "'")
    CountVille = 0
    Do Until rsCVille.EOF
    VL = LCase(rsCVille.Fields("Ville"))
    tVL = LCase(cboVille.Text)
    If VL = tVL Then
    CountVille = CountVille + 1
    nrVille = rsCVille.Fields("PcID")
    cboVille.Text = rsCVille.Fields("ville")
    Else
    End If
    rsCVille.MoveNext
    Loop
    end if


    When I Click on the cbo, the listindex follows, but when I just type it, it doesn't.

    How come and how can it be solved

    thx

  2. #2
    Join Date
    Dec 2002
    Location
    London, UK
    Posts
    1,569
    which cbo... you have quite a few...
    please re-write you question giving only the required code and make it a bit more clear what you ar trying to do and what the problem is. Thanks
    Mike

  3. #3
    Join Date
    Jan 2002
    Location
    Quebec/Canada
    Posts
    124
    I think you have to set the style of your Combo to 2 - Dropdown List.

  4. #4
    Join Date
    Jul 2003
    Posts
    12
    It's all about cbo-ville

    and the style of the cbo-box has to stay on 0 - Dropdown Combo
    because else i can't get a list and type in the box

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

Featured