Wrox Programmer Forums
Go Back   Wrox Programmer Forums > .NET > Other .NET > General .NET
|
General .NET For general discussion of MICROSOFT .NET topics that don't fall within any of the other .NET forum subcategories or .NET language forums.  If your question is specific to a language (C# or Visual Basic) or type of application (Windows Forms or ASP.Net) try an applicable forum category. ** PLEASE BE SPECIFIC WITH YOUR QUESTION ** When posting here, provide details regarding the Microsoft .NET language you are using and/or what type of application (Windows/Web Forms, etc) you are working in, if applicable to the question. This will help others answer the question without having to ask.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the General .NET section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old December 10th, 2004, 08:33 PM
Registered User
 
Join Date: Dec 2004
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default crystalreportviewer and paging

Hi everyone,

I am trying to use crystal report in asp.net. reports first page is displayed successfully but when I go to the next page report is not displayed but instead a report viewer control is displayed. If I try to refresh the report then also the report viewer control is displayed. Only the first page works fine. I was wondering if there is any paging control in crystalreportviewer.
This is the code that I am using
Dim oConnection As New SqlClient.SqlConnection("server=(local); database = test; Trusted_connection=yes ")
oConnection.Open()
Dim contentType As String
Dim oCommand As New _
SqlClient.SqlCommand("select * from tmpRptCheckRegister", oConnection)


Dim ds As New DataSet()

Dim oDataAdapter As New SqlClient.SqlDataAdapter(oCommand)

oDataAdapter.Fill(ds, "oClaims")

Dim rpt As New CrystalReport1()
rpt.SetDataSource(ds.Tables("oClaims"))
CrystalReportViewer1.ReportSource = rpt

This code works fine because data is coming in the dataset and first page is displayed sucessfully. I tried to keep this code inside the isnotpostback statment and also outside the if isnotpostback statemnet. It shows the crystalreportviewer if it is inside the If isnotpostback statement and it keeps on showing page 1 after refresh or when I try to go to next page when I keep this code outside the if notpostback statement.

Any help will be greatly appreciated.








Similar Threads
Thread Thread Starter Forum Replies Last Post
Paging in CrystalReportViewer rakeshvc Crystal Reports 1 May 19th, 2014 06:18 AM
DB recordset paging using ajax paging? kumiko Classic ASP Basics 0 May 26th, 2008 10:23 AM
two reports in one CrystalReportViewer sali Crystal Reports 2 August 7th, 2007 12:29 AM
CrystalReportViewer paging problem AVeldkamp Crystal Reports 13 August 4th, 2006 03:19 AM
crystalreportviewer and paging vinki Crystal Reports 0 December 10th, 2004 08:32 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.