sqltransaction tans=null; open.con() //to opendatabase connection begintransaction(); _db.save('i',"2",trans); _db.GetArea("China",trans); public datatable GetArea(string name,sqltransaction trans) { string query ="select * from Area where AreaName='"+name+"'"; datatable dt = new datatable() dt= con.open.getdatatable(query,trans); } public datatable getdatatable(string SelectQuery,sqltransaction) { SqlDataAdapter da = new SqlDataAdapter(SelectQuery, Class1.Connection); System.Data.DataTable dt = new System.Data.DataTable(); //'hbug' try { da.Fill(dt); return dt; } catch { throw; } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)