ReportDocument.PublishHTML
Returns an object that is an HTML representation of a Report Document object.
Use PublishHTML with the Publish method create an HTML version of a Report Document object. PublishHTML returns an object which Publish then outputs to a series of files in a directory. The report can be viewed using a browser.
Object
Read
This example opens the Annual Product Sales report and publishes it as HTML. The Publish method places the HTML files into the folder called tmp and all the files have the prefix myfiles.
Sub Main()
Dim objImpApp as Object
Dim objHTML as Object
Dim objImpRep as Object
Set objImpApp = CreateObject("CognosImpromptu.Application")objImpApp.OpenCatalog "c:\Program Files\Cognos\<rendition_id>\" & _
"samples\Impromptu\Reports\Great Outdoors Sales Data.cat" _
,"Creator"
Set objImpRep = objImpApp.OpenReport("c:\Program Files\"
& _"Cognos\<rendition_id>\samples\Impromptu\Reports\" & _
"Annual Product Sales.imr")
Set objHTML = objImpRep.PublishHTML
objHTML.Publish "c:\tmp","myfiles"
Set objImpRep = Nothing
Set objHTML = Nothing
Set objImpApp = Nothing
End Sub