예제 #1
0
 protected void btnSystemAttachUpload_Click(object sender, EventArgs e)
 {
     if (Request.QueryString["RefHandle"] != null && Request.QueryString["RefIndex"] != null)
     {
         divTransmittalScreen.Visible = true;
         objAttachmentcls             = new AttachmentCls();
         // objAttachmentcls.IndexValue = Request.QueryString["Index"];
         objAttachmentcls.AttachmentHandle = Request.QueryString["RefHandle"];
         objAttachmentcls.IndexValue       = Request.QueryString["RefIndex"];
         DataTable dt = objAttachmentcls.GetExistingAttachment();
         if (dt.Rows.Count > 0)
         {
             // Session["sDocumentId"] = dt.Rows[0]["t_dcid"].ToString();
             //// Session["sFileName"] = dt.Rows[0]["t_fnam"].ToString();
             // Session["sLibCode"] = dt.Rows[0]["t_lbcd"].ToString();
             // Session["sattachedby"] = dt.Rows[0]["t_atby"].ToString();
             divViewExistingAttachment.Visible  = true;
             divExistingAttachNotExists.Visible = false;
             btnCopyAttachment.Visible          = true;
             gvExistingAttachments.DataSource   = dt;
             gvExistingAttachments.DataBind();
         }
         else
         {
             divExistingAttachNotExists.Visible = true;
             divViewExistingAttachment.Visible  = false;
         }
     }
     {
         // No Attachment exists for the provide reference handle and reference Index
     }
 }