Renders a web page specified by URL.




ImageID = Doc.AddImageUrl(Url [, Paged[, Width[, DisableCache]]])



Name Type Description
Url String The URL for the page to be rendered.
Paged Boolean Allows you to override the default XHtmlOptions.Paged property (optional).
Width Long Allows you to override the default XHtmlOptions.BrowserWidth property (optional).
DisableCache Boolean

Allows you to override and disable the page cache (optional).

See the XHtmlOptions.PageCacheEnabled property for details.

ImageID Long The ID of the newly added View object.




This method adds a web page to a document.

The page is added in accordance with the current XHtmlOptions settings. As a convenience, you can override the more commonly used settings as detailed above.

Only the first page of the document is drawn. Subsequent pages can be drawn using the AddImageToChain method.

The web page is scaled to fill the current Rect. It is transformed using the current Transform.

Caching. Sometimes, you may find that pages appear to be cached.

If you are using AddImageUrl, it is possible that the URL is in some way being cached. So the PDF may be changing, but the content within it may be staying the same. See the HTML / CSS Rendering section of the documentation for details.

Alternatively, it is possible that the PDF itself is being cached. Most commonly, this can happen if you're streaming the PDF direct to the browser and you have certain IIS settings (like Expire Content) disabled.

Your first step should be to narrow down the problem. Why not save the PDF to disk at the same time as sending it to the client? That way you can establish whether the PDF itself is being cached or whether the content is in some way being cached (resulting in the same PDF being created again and again).

If the PDF is being cached, you will need to look at your IIS settings. ABCpdf is not doing the caching (and indeed, it cannot cache the PDF in this way); it will be something which is happening either in IIS/ASP or on an intervening proxy server or on the client.




We create an ABCpdf Doc object, add our URL and save. That's it!

Set theDoc = Server.CreateObject("ABCpdf10.Doc")
theDoc.AddImageUrl ""
theDoc.Save "c:\mypdfs\htmlimport.pdf"

We get the following output.


For an example of how to use paged HTML, see the AddImageToChain method.