This example shows the how to exert a higher degree of control over the rendering process.

 

   
Setup
 
     

First we create an ABCDrawHTML Page object and set the URL.

Set thePage = Server.CreateObject("ABCDrawHTML.Page")
thePage.URL = "http://www.whitehouse.gov/"

 

   
Page
 
     

The default size at which the HTML is rendered is 800 pixels by 600 pixels. However we're going to want a preview which reflects how the HTML would look on a 640 by 480 monitor and so we reduce the page size.

thePage.Width = 640
thePage.Height = 480

 

   
Image
 
     

We want two images produced - one smaller PNG and one larger JPEG. Accordingly we save these two out.

thePath = Server.MapPath("whsmall.png")
thePage.Save thePath, 80, 60
thePath = Server.MapPath("whbig.jpg")
thePage.Save thePath, 240, 180

 

   
Results
 
     


whsmall.png


whbig.jpg