i create 2 combobox in form, comboproduct & combomodel.
i using accessdatabase and using oledbconnection..database in debug folder...
i create 1 table, i name it"stock" & 2 column..
first column is product,second model..


i wont load data in product column into comboproduct and model to combomodel..like binding data..

anyone help me..

arezz09, you already mark this thread as solved.
Would you like to share with us how you solve it ? So, when another member read your thread they will get the answer too.

Thanks.

commented: :) +1

use this if help...

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

        Dim conn As New OleDbConnection("provider=microsoft.jet.OleDb.4.0;Data Source=" & Application.StartupPath & "\stock.mdb")

        Dim cmd As OleDbCommand = New OleDbCommand("SELECT product,model FROM stock", conn)

        conn.Open()

        Dim sdr As OleDbDataReader = cmd.ExecuteReader

        While sdr.Read()

            comboproduct.Items.Add(sdr.Item("product").ToString)
            combomodel.Items.Add(sdr.Item("model").ToString)

        End While

        conn.Close()

        conn = Nothing

    End Sub
End Class

this should work..

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.