gopakumar k

gopakumar k

  • NA
  • 57
  • 412

How can i bind the model class field to text field

Aug 29 2018 4:48 AM
I Need to bind the model class data fields into the fields which i created for the CRUD operations.Already have an option to do this one by one like as follows
employee emp=new employee();
emp=get_employee_id(1); 
txtage.Text = .emp.age.ToString();
txtname.Text = .emp.name.ToString(); 
But i need to map the fields directly to the model class field and whenever get the data in emp object, the text fields need to be automatically filled.And it will reduce my code, other wise i need to map it one by one.
I checked one solution for the above problem by adding the binding to the text field from the properties option by choosing 'Data Bindings'  but that also not working.Please update an posible solution.
Thanks in advance. 
Regards
Gopakumar 

Answers (1)