Binding

G

Guest

I have creating VB .NET form with ADO .NET which have 2 textbo
and have set DataBindings to
the text properties of the TextBoxes
i bind the the box with
txtsysno.DataBindings.Add(new binding("Text", dataset1, "trxsystem.sysno")
txtbranch.DataBindings.Add(new binding("Text", dataset1, "trxsystem.branch")
when the form run, i place a method when a button clic
txtsysno.text = "Z001
when i trace it, the txtsysno.text = "Z001" and i set the branch value throught the dataset wit
dataset1.tables(0).Rows(0)("Branch") = e.SelectedRow(1)
after i run the above code, the txtsysno was set to "", i don't know what makes this happen an
BUT according to tests I've run, it
says that the DataBindings exist, but the IsBinding is set to False, and
is ReadOnly (the bindings exist, they just aren't active AND I
can't/don't know how to make them active)
Any body can help me??? thanks before
 
S

Sanjeeva

I have a nice example of DataBinding... If you need... but I dont know how
to post
attatchements on groups...

Regards
Sanjeeva
 
S

Sanjeeva

I have two text boxes which are bound to same table as a datagrid.



on button click write this code to see DataBingin in action...



private void button1_Click(object sender, System.EventArgs e)

{

dataGrid1.BindingContext[ dataSet1,
dataTable1.TableName ].Position += 1;

}
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top