Example #1
0
    protected void gvMNE_RowCommand(object sender, GridViewCommandEventArgs e)
    {
        var command = e.CommandName;
        var id      = e.CommandArgument;

        if (command.Equals("Modify", StringComparison.InvariantCultureIgnoreCase))
        {
            Response.Redirect(string.Format("modifymnedetails.aspx?Id={0}", id));
        }

        if (command.Equals("Remove", StringComparison.InvariantCultureIgnoreCase))
        {
            var sid = Sars.Systems.Security.ADUser.CurrentSID;
            DBWriteManager.DeleteMultinational(Convert.ToDecimal(id), sid);
            MessageBox.Show("Record Deleted successfully");
            LoadMNEList();
        }
    }