VBcoders Guest



Don't have an account yet? Register
 


Forgot Password?



Check Combo for the existing Data and scans for new entry in combo box

by Aamir Nazir Butt (1 Submission)
Category: Custom Controls/Forms/Menus
Compatability: VB 6.0
Difficulty: Unknown Difficulty
Originally Published: Sun 4th January 2004
Date Added: Mon 8th February 2021
Rating: (1 Votes)

Check Combo for the existing Data and scans for new entry in combo box

API Declarations


Set VH = DB.OpenRecordset("Vehicle")


Rate Check Combo for the existing Data and scans for new entry in combo box



Combo1.Clear
VH.Index = "VehIDNo"
    If VH.RecordCount > 0 Then
        VH.MoveFirst
        Combo1.Text = VH(0)
        Combo1.AddItem VH(0)
        Do While Not VH.EOF
            If Combo1.Text <> VH(0) Then
                Combo1.AddItem VH(0)
            End If
            Combo1.Text = VH(0)
            VH.MoveNext
       Loop
    End If
Combo1.Text = ""
End Sub


Download this snippet    Add to My Saved Code

Check Combo for the existing Data and scans for new entry in combo box Comments

No comments have been posted about Check Combo for the existing Data and scans for new entry in combo box. Why not be the first to post a comment about Check Combo for the existing Data and scans for new entry in combo box.

Post your comment

Subject:
Message:
0/1000 characters