Added check for null PDF file name (happens when there is no procedure number).

This commit is contained in:
John Jenko 2014-01-22 15:11:20 +00:00
parent 739f6894ea
commit 749b675438

View File

@ -303,6 +303,7 @@ namespace VEPROMS
PDFFileName = string.Format("{0}", _MyProcedure.PDFNumber);
//if (txbPDFName.Text.StartsWith("*"))
// txbPDFName.Text = txbPDFName.Text.Replace("*", this.UnitNumber);
if ((PDFFileName ?? "") == "") PDFFileName = "NoProcNumber";
if (PDFFileName.StartsWith("*"))
PDFFileName = PDFFileName.Replace("*", this.UnitNumber);
txbPDFName.Text = PDFFilePrefix + PDFFileName + PDFFileSuffix + ".pdf";