Hi All,
iam using Button Control When User Click the Button only Records is Erase in Table in the Below My Script where iam doing Wrong Let me Know.
sql connction con = new sql connction ("Data Source=sys2;Initial Catalog=MuraliIIT;User ID=sa;Password=rits@1234");
string s = "Truncate Table TableName";
sqladapter da = new sql Adapter(s,con);
Dataset ds = new Dataset ();
da.fill(ds,"TableName");
string s = "Truncate Table TableName";
sqladapter da = new sql Adapter(s,con);
Dataset ds = new Dataset ();
da.fill(ds,"TableName");


Manoj BhoirRank #599 · 4K reputationPosted Jun 5, 2015, 9:20 AM EDT
string s = "Truncate Table TableName";
Com.ExecuteNonQuery();
Jitendra KumarRank #760 · 3K reputationPosted Jun 5, 2015, 2:16 AM EDT
If you are running your code against a sqlserver database then
use this command
Rajkiran SwainRank #165 · 14.4K reputationPosted Jun 5, 2015, 5:46 AM EDT
Pankaj Kumar ChoudharyRank #80 · 24.4K reputationPosted Jun 5, 2015, 8:23 AM EDT
Com.ExecuteNonQuery();