Posted on: 9/9/2015 4:01:46 PM | Views : 787

I have a C# application(WCF-Soap Service) that is creating PDF documents and save in in the Path that comes from webconfig. Consider for example path is: C:\Doc\Pdf\ that in the code path is inlocation variable. I like to generate folders for each day and put the pdfs for that day on its folder. I tried to use CreateDirectory but I don’t know how specify name of the folder to generate.
this code only save the PDF in the C:\Doc\Pdf\ and it is not creating any directory.
this is my code:
string pdfFileName = "Application" + "_" + documentData.APPLICATIONDATE.ToString("MMddyyyy") + "_" + documentData.APPLICATIONDATE.ToString("hhmmsstt") + "_" + documentData.BorrowerLastName; location = ConfigurationManager.AppSettings["PdfPath"].ToString(); DirectoryInfo di =System.IO.Directory.CreateDirectory(lo ...

Go to the complete details ...