Sreekanth Reddy

Sreekanth Reddy

  • 337
  • 4.8k
  • 407.5k

message displaying as row created or row inserted in web pag

Mar 7 2014 1:27 PM
Hai friends,
While doing insertion by LINQ how to make to display a message as "row is inserted" in label.
 
protected void Button1_Click(object sender, EventArgs e)
{
int a = Convert.ToInt32(TextBox1.Text);
string b = TextBox2.Text;
string c = TextBox3.Text;
int d = Convert.ToInt32(TextBox4.Text);
obj.studetails.InsertOnSubmit(stuobj);
obj.SubmitChanges();
 
//Here how to display as row is inserted in my lable1?
 
//in data.sqlclient i can do it as...
// int x=cmd.executeNonQuery();
//if(x==1)
//{
//label1.text="row inserted"; 
//}
 
//How with LINQ? 
}
 PLEASE REPLY..............