Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > .NET > Other .NET > Crystal Reports
Password Reminder
| FAQ | Members List | Search | Today's Posts | Mark Forums Read
Crystal Reports General discussion about Crystal Reports. For discussions specific to the book Professional Crystal Reports for VS.NET, please see the book discussion forum for that book.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Crystal Reports section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old February 16th, 2006, 12:26 AM
Authorized User
Join Date: Aug 2005
Location: , , .
Posts: 25
Thanks: 0
Thanked 0 Times in 0 Posts
Default What is wrong witht his crystal report code


I am using the following code to retrieve my report. I am using Asp.net(version 1.1) & sql 2000 & Crystal Reports 9. My query is retrieving exact result to the xml file, but crystal report is not retrieving the exact result, it's not taking the condition of the query, it simpy shows all teh recrds in the table. Can you please help me to solve this


crpt = New BlueRegisterEnglish

'crpt = New Form1A
Dim cmd As New SqlCommand
Dim Da As New SqlDataAdapter
Dim Ds As New DataSet
Dim SchoolID As String
SchoolID = "AB0"
Dim ClassID As String
ClassID = "1-A"

For Each myTable In crpt.Database.Tables
myLogin = myTable.LogOnInfo
myLogin.ConnectionInfo.ServerName = "IBRA"
myLogin.ConnectionInfo.DatabaseName = "FSchool"
myLogin.ConnectionInfo.Password = "123"
myLogin.ConnectionInfo.UserID = "sa"
Dim myConnection As SqlConnection
Dim mySqlDataAdapter As SqlDataAdapter

myConnection = New SqlConnection("server=IBRA; uid=sa; pwd=123; database=FSchool")
Da = New SqlDataAdapter("Select * From tmpblueregister Where SchoolID = '" & SchoolID & "' and class= '" & ClassID & "'", myConnection)
Da.Fill(Ds, "TmpForm1A")
CrystalReportViewer1.ReportSource = crpt

Reply With Quote

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Code for Exporting Crystal Report to Excel or PDF shakti_2505270 ASP.NET 2.0 Professional 1 October 4th, 2007 01:00 AM
Crystal Report 11 subreport code.... intellogo Pro VB Databases 0 April 7th, 2007 08:46 AM
Crystal Report displays wrong value. shilpa_net2004 VB Databases Basics 2 December 31st, 2005 12:09 PM
Crystal Report displays wrong value. shilpa_net2004 Crystal Reports 0 December 13th, 2005 04:30 AM
Calling Crystal report from Java code anubhav.kumar BOOK: Beginning Java 2, JDK 5 Edition 0 May 24th, 2005 08:46 AM

All times are GMT -4. The time now is 09:20 AM.

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