How do i bind textbox to the data whose selection crieteria is based on 2 combo boxes.
I want to use sql and where clause.
right now I am using the following
dt = New DataTable
da = New MySqlDataAdapter("SELECT rates FROM tblratesmaster where date_entry=ComboBox1.selectedindex and broker_firm = ComboBox2.selectedindex", myconnstring)
da.Fill(dt)
cb = New MySqlCommandBuilder(da)
bs.DataSource = dt
TextBox1.DataBindings.Add(New Binding("Text", bs, "rates"))
and I am getting nothing when I run it
I want to use sql and where clause.
right now I am using the following
dt = New DataTable
da = New MySqlDataAdapter("SELECT rates FROM tblratesmaster where date_entry=ComboBox1.selectedindex and broker_firm = ComboBox2.selectedindex", myconnstring)
da.Fill(dt)
cb = New MySqlCommandBuilder(da)
bs.DataSource = dt
TextBox1.DataBindings.Add(New Binding("Text", bs, "rates"))
and I am getting nothing when I run it