var context = new LinqSampleDataContext(SPContext.Current.Web.Url);
EntityList<LoginItem> login_Insert =
context.GetList<LoginItem>("Login");
var query = from cs in login_Insert
where cs.Title.ToString() == txtUserName.Text
select new
{
cs.Title,
cs.Password
};
var UpadteQuery = context.Login.SingleOrDefault(cs =>
cs.Title == txtUserName.Text);
if (UpadteQuery != null)
{
UpadteQuery.Password = txtPassWord.Text;
context.SubmitChanges();
}
this.Controls.Add(new LiteralControl("Updation
Sucessful"));
EntityList<LoginItem> login_Insert =
context.GetList<LoginItem>("Login");
var query = from cs in login_Insert
where cs.Title.ToString() == txtUserName.Text
select new
{
cs.Title,
cs.Password
};
var UpadteQuery = context.Login.SingleOrDefault(cs =>
cs.Title == txtUserName.Text);
if (UpadteQuery != null)
{
UpadteQuery.Password = txtPassWord.Text;
context.SubmitChanges();
}
this.Controls.Add(new LiteralControl("Updation
Sucessful"));
No comments:
Post a Comment