public DocHostUIHandler(CaptureBrowserImage hostControl)
        {
            if ((hostControl == null) || (hostControl.IsHandleCreated == false)) {
                throw new ArgumentNullException("hostControl");
            }

            this.hostControl = hostControl;
        }
        public static void SaveAsImage(string 
			url, string pngFile)
        {
            // create a hidden control and tell it to DoIt()
            // todo: cleanup after exceptions
            CaptureBrowserImage captureBrowser = new
                CaptureBrowserImage();
            captureBrowser.CreateControl();
            captureBrowser.CaptureImage(url, pngFile);
            captureBrowser.Dispose();
        }