private void GetAttachments(decimal incidentId) { uploaderPreventativeMeasures.SetAttachmentRecordStep("1"); uploaderPreventativeMeasures.SetReportOption(false); uploaderPreventativeMeasures.SetDescription(false); // Specifying postback triggers allows uploaderPreventativeMeasures to persist on other postbacks (e.g. 8D checkbox toggle) // uploaderPreventativeMeasures.RAUpload.PostbackTriggers = new string[] { "btnSubnavSave", "btnSaveReturn", "btnSaveContinue", "btnDelete", "btnDeleteInc", "btnSubnavIncident", "btnSubnavContainment", "btnSubnavRootCause", "btnSubnavAction", "btnSubnavApproval", "btnSubnavAlert" }; int attCnt = EHSIncidentMgr.AttachmentCount(incidentId); //add values 2 for getting the PreventativeMeasures attachment. int px = 128; if (attCnt > 0) { px = px + (attCnt * 30) + 35; //uploaderPreventativeMeasures.GetUploadedFilesforPreventativeMeasures(40, incidentId, ""); uploaderPreventativeMeasures.GetUploadedFilesIncidentSection(40, incidentId, "", (int)Incident_Section.PreventativeMeasuresAttachment); } else { uploaderPreventativeMeasures.GetBlinkATTACHMENT(); } /* * */ // Set the html Div height based on number of attachments to be displayed in the grid: //dvAttachLbl.Style.Add("height", px.ToString() + "px !important"); //dvAttach.Style.Add("height", px.ToString() + "px !important"); }