Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

datagrid saving changes

Status
Not open for further replies.

ernatlas

Programmer
Joined
Jan 17, 2007
Messages
8
Location
MX
Hello, i have a question. I have this datagrid that i`m working on. It shows three fields from a table called "empleado". Does anyone knows, how to apply the changes in the datagrid, directly in the database ??

string ConnectionString = "Driver={MySQL ODBC 3.51 Driver};
Server=localhost;Database=Reloj;option=3";
string myquery = "SELECT app, apm, nombre FROM empleado";
dbcDataAdapter MySQLDataAdapter = new OdbcDataAdapter(myquery,ConnectionString);
MySQLDataSet = new DataSet();
MySQLDataSet.AcceptChanges();
MySQLDataAdapter.Fill(MySQLDataSet,"empleado");
mysqlTable.DataSource = MySQLDataSet.Table["empleado"].DefaultView;
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top