Exemplo n.º 1
0
 protected void gvFuneral_RowCommand(object sender, GridViewCommandEventArgs e)
 {
     if (e.CommandName == "EditFuneral")
     {
         FID = Convert.ToInt32(e.CommandArgument);
         try
         {
             BindFuneralToUpdate();
         }
         catch (Exception exc)
         {
             ShowMessage(ref lblMessage, MessageType.Danger, exc.Message);
             lblMessage.Visible = true;
         }
     }
     if (e.CommandName == "DeleteFuneral")
     {
         client.FuneralDelete(Convert.ToInt32(e.CommandArgument), UserName);
         bindFuneralList();
     }
     if (e.CommandName == "PrintFuneral")
     {
         FID = Convert.ToInt32(e.CommandArgument);
         try
         {
             PrintQuotation();
         }
         catch (Exception exc)
         {
             ShowMessage(ref lblMessage, MessageType.Danger, exc.Message);
             lblMessage.Visible = true;
         }
     }
 }