public void SaveToFileStream() { string outputPath = "Documents/SaveToFileStream.pdf"; File.Delete(outputPath); using (FileStream stream = File.OpenWrite(outputPath)) { PdfTemplate template = PdfTemplate.Open("Documents/Template.pdf"); template.RemoveUsageRights = true; template.Save(stream); } OldFileAssert.Exists(outputPath); }
public void InvalidFileNameForSave(string fileName) { PdfTemplate form = PdfTemplate.Open("Documents/Template.pdf"); form.Save(fileName); }