I have built a Crystal Report in VS2008 for an asp.net c# site. I can run the rpt file and view the report.
I can't get it do display in the web page.
I've never used Crystal before so I may have this totally wrong. I dragged a CrystalReportViewer and CrystalReportSource onto the designer and used the menu to configure the source and report name.
<%@ Page Language="C#" MasterPageFile="~/TimeTracker/MasterPage.master" AutoEventWireup="true" CodeFile="EmployeeReport.aspx.cs" Inherits="TimeTracker_EmployeeReport" Title="Untitled Page" %>
<%@ Register Assembly="CrystalDecisions.Web, Version=10.5.3700.0, Culture=neutral, PublicKeyToken=692fbea5521e1304"
Namespace="CrystalDecisions.Web" TagPrefix="CR" %>
<asp:Content ID="Content1" ContentPlaceHolderID="maincontent" Runat="Server">
<CR:CrystalReportViewer
ID="CrystalReportViewer1"
runat="server"
AutoDataBind="True"
Height="1200px" ReportSourceID="CrystalReportSource1"
Width="1000px" HasRefreshButton="True" />
<CR:CrystalReportSource ID="CrystalReportSource1" runat="server">
<Report FileName="EmployeeHours.rpt">
</Rep开发者_运维百科ort>
</CR:CrystalReportSource>
</asp:Content>
Where is EmployeeHours.rpt actually located? If it's in the sub folder TimeTracker try this:
FileName="~/TimeTracker/EmployeeHours.rpt".
Does the page generate any javascript errors like object bobj is undefined?
Are you getting errors? You need to have Crystal installed on your web server.
精彩评论