General information
Title:
How to bind textbox, checkbox
Environment versions
Network:
Windows 2003 Server
Hello The C# Expert,
I am googling to find how to bind textbox, checkbox (view, insert,update,delete)..
I found below routine..
but some limitations;
- unable to bind checkbox .. it return error (String was not recognized as a valid Boolean)
- unable to do insert,update,delete.
I need help
TIA
public void BindField(Control control, string propertyName, object dataSource, string dataMember)
{
Binding bd;
for(int index = control.DataBindings.Count - 1; (index == 0); index--)
{
bd = control.DataBindings[index];
if(bd.PropertyName == propertyName)
control.DataBindings.Remove(bd);
}
control.DataBindings.Add(propertyName, dataSource, dataMember);
}
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only