Saves the document as PDF.




Doc.Save Path



Name Type Description
Path String The destination file path.




Use this method to export the current document as PDF. The supplied path is used as the destination. Any existing file will be overwritten.

ABCpdf operates an intelligent just-in-time object loading scheme, which ensures that only those objects that are required are loaded into memory. This means that if you are modifying large documents, then server load will be kept to a minimum. The original PDF document must be available for as long as the Document object is being used.

As a result, you cannot overwrite a PDF file while it is open for reading. You will need to save your PDF to another location and then swap the two files round.

If you need to obtain a PDF as raw data, you can use the GetData method.

Versions. ABCpdf automatically determines the PDF version depending on the features you use. If you use features from only the 1.1 specification, it will write a 1.1 PDF. If you use 1.3 features, it will write a 1.3 PDF. If you use 1.4 features, it will write a 1.4 PDF. Ditto 1.5 and 1.6.

If you're using a PDF template or drawing from another PDF, the final output will be the minimum version used in these templates. In many real world applications, this will be the factor which determines the version in the final output produced by ABCpdf.

There is no advantage in producing a 1.6 document if you're not using features from the 1.6 feature set. To do this will simply stop users of older versions of Acrobat from accessing a document which should be available to them.




The following code illustrates how one might add text to a PDF and then save it out.

Set theDoc = Server.CreateObject("ABCpdf10.Doc")
theDoc.FontSize = 96
theDoc.AddText "Hello World"
theDoc.Save "c:\mypdfs\docsave.pdf"