示例#1
0
 protected void tblmyApplications_OnRowDeleting(object sender, GridViewDeleteEventArgs e)
 {
     try
     {
         var     del_id      = tblmyApplications.DataKeys[e.RowIndex].Values[0].ToString();
         var     credentials = new NetworkCredential(ConfigurationManager.AppSettings["W_USER"], ConfigurationManager.AppSettings["W_PWD"], ConfigurationManager.AppSettings["DOMAIN"]);
         Portals sup         = new Portals();
         sup.Credentials     = credentials;
         sup.PreAuthenticate = true;
         if (sup.FnDeleteScholarship(del_id) == true)
         {
             ScriptManager.RegisterStartupScript(this, this.GetType(), "Pop", "alert('Application Entry deleted successfully!');", true);
             LoadMyApplications();
         }
     }
     catch (Exception ex)
     {
         //KCDFAlert.ShowAlert(ex.Message);
         ScriptManager.RegisterStartupScript(this, this.GetType(), "Pop", "alert('" + ex.Message + "');", true);
         LoadMyApplications();
     }
 }