Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CrViewer via IE 5.5

Status
Not open for further replies.

FoxG

Technical User
Jun 1, 2001
393
0
0
GB
I obtained this from a page on the web.
This Html script works fine for the report specified.
What would you need to change to make it work for a different report?
(Eg. generated via an ODBC link to a SQL server database?

Any info would be appreciated,
Geoff

<html>
<head>
<TITLE>Crystal Report Viewer</TITLE>
</head>
<SCRIPT LANGUAGE=&quot;JavaScript&quot;>
</SCRIPT>
<BODY BGCOLOR=C6C6C6 LANGUAGE=VBScript>

<OBJECT ID=&quot;CRViewer&quot;
CLASSID=&quot;CLSID:C4847596-972C-11D0-9567-00A0C9273C2A&quot;
WIDTH=100% HEIGHT=95%
CODEBASE=&quot;/viewer/activeXViewer/activexviewer.cab#Version=8,0,0,371&quot;>
<PARAM NAME=&quot;EnableDrillDown&quot; VALUE=1>
<PARAM NAME=&quot;EnableExportButton&quot; VALUE=1>
<PARAM NAME=&quot;DisplayGroupTree&quot; VALUE=1>
<PARAM NAME=&quot;EnableGroupTree&quot; VALUE=1>
<PARAM NAME=&quot;EnableAnimationControl&quot; VALUE=1>
<PARAM NAME=&quot;EnablePrintButton&quot; VALUE=1>
<PARAM NAME=&quot;EnableRefreshButton&quot; VALUE=1>
<PARAM NAME=&quot;EnableSearchControl&quot; VALUE=1>
<PARAM NAME=&quot;EnableZoomControl&quot; VALUE=1>
<PARAM NAME=&quot;EnableSearchExpertButton&quot; VALUE=0>
<PARAM NAME=&quot;EnableSelectExpertButton&quot; VALUE=0>
</OBJECT>

<SCRIPT LANGUAGE=&quot;VBScript&quot;>
<!--

Sub window_onLoad()
Page_Initialize()
End Sub

Sub Page_Initialize
On Error Resume Next
Dim webBroker
Set webBroker = CreateObject(&quot;WebReportBroker.WebReportBroker&quot;)
if err.number <> 0 then
window.alert &quot;The Seagate Software ActiveX Viewer is unable to create it's resource objects. To rectify this problem, please install Internet Explorer 4.0 or install DCOM for Windows 95 and the latest Microsoft Scripting Engine. These files are available at Microsoft's web site.&quot;
CRViewer.ReportName = &quot; else
Dim webSource0
Set webSource0 = CreateObject(&quot;WebReportSource.WebReportSource&quot;)
webSource0.ReportSource = webBroker
webSource0.URL = &quot; webSource0.PromptOnRefresh = True
webSource0.AddParameter &quot;password0&quot;, &quot;scr&quot;
webSource0.AddParameter &quot;user0&quot;, &quot;scr&quot;

CRViewer.ReportSource = webSource0
end if
CRViewer.ViewReport
End Sub

-->
</SCRIPT>
</body>
</html>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top