protected void BtnSave_Click(object sender, EventArgs e)
{
if (BtnSave.Text == "Save")
{
Save();
Message("Data Inserted Successfully .!");
DropDownList DdlGroup = (DropDownList)this.Parent.FindControl("ddlGroup");
if (DdlGroup != null)
{
List<UFMS_Group> listGroup = new List<UFMS_Group>();
listGroup = UERPManagement.GetInstance.GetAllGroups();
var lnqGroup = from grp in listGroup
select grp;
DdlGroup.DataSource = lnqGroup.ToList();
DdlGroup.DataTextField = "Group_Name";
DdlGroup.DataValueField = "Group_ID";
DdlGroup.DataBind();
DdlGroup.Items.Insert(0, UserCommand.Select.ToString());
}
}
else
{
update();
//FillGridViewGroup();
Message("Data Updated Successfully .!");
}
}
{
if (BtnSave.Text == "Save")
{
Save();
Message("Data Inserted Successfully .!");
DropDownList DdlGroup = (DropDownList)this.Parent.FindControl("ddlGroup");
if (DdlGroup != null)
{
List<UFMS_Group> listGroup = new List<UFMS_Group>();
listGroup = UERPManagement.GetInstance.GetAllGroups();
var lnqGroup = from grp in listGroup
select grp;
DdlGroup.DataSource = lnqGroup.ToList();
DdlGroup.DataTextField = "Group_Name";
DdlGroup.DataValueField = "Group_ID";
DdlGroup.DataBind();
DdlGroup.Items.Insert(0, UserCommand.Select.ToString());
}
}
else
{
update();
//FillGridViewGroup();
Message("Data Updated Successfully .!");
}
}
No comments:
Post a Comment