0

hi i am making pos system i am using msflexgrid.. and i have make combo box visible when user clicks on grid... i have data combo which contains all supplier company name.... now my problem is that i want to load the combo box with relevant products as user selects Supplier company name...i dont want to show all products... i only want to load the products whos supplier name = dataCmbo.Text and the most important i want to do it by using Adodc...
what i am doing is this(See in picture)...when programs load it does not give any error but it also dont add any record in combo box also.. please help me as early as possible it is urgent.
there is some problem in sql statement of adodc please figure it out.
(Please Check attachments)

my code to load combo is this..

Dim vrnt As Variant
            With Adodc4.Recordset
             Do While Not .EOF
            vrnt = ![Product_Name]
            If IsNull(vrnt) Then vrnt = ""
            Combo1(0).AddItem CStr(vrnt)
            .MoveNext
            Loop
         End With
2
Contributors
2
Replies
3
Views
7 Years
Discussion Span
Last Post by vb5prgrmr
0

Please why you are not helping me, i dont have time coz i have to present my project on 3rd sep please reply me today please please.......

0

Well to begin with, I would change you varient variable to a string. Then I would check to see if that string equaled vbNullString and if it didn't, then add the value retrieved from the database. Otherwise, why add an empty string to a combo box.

Good Luck

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.