Wrox Programmer Forums
Go Back   Wrox Programmer Forums > .NET > Other .NET > Crystal Reports
|
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 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 May 25th, 2006, 12:34 AM
Registered User
 
Join Date: May 2006
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default Eporting Crystal Report

While exporting crystal report, if u've mutiple values for one parameter fild of CR, u can use following code,
it's working fine........




Private Function SetParameterVal()

    Dim paramField As New ParameterField

    '''******** Get the parameter values in a data reader **********'''

        strDr = object1.GetSelectedYearDataReader(Year)

    '''******** Put it in a while-loop **********'''


        While strDr.Read


            discreteVal = New ParameterDiscreteValue '''' ******* Put this line to avoid over-writing *******''''

            discreteVal.Value = (strDr(0)) '''' ******* Set the DR value to ur discrete-value *******''''

            paramField.CurrentValues.Add(discreteVal) '''' ******* Add it to parameter fied ( b-coz it can store multiple values ) *******''''

            crReportClass.SetParameterValue(0, paramField.CurrentValues) '''' ******* Set that value to ur desire index no. *******''''


        End While



 End Function

Nikhil





Similar Threads
Thread Thread Starter Forum Replies Last Post
simple report and crystal report in vb.net saket123 .NET Framework 2.0 0 August 13th, 2008 06:55 AM
VS 2002 Crystal Report opens Seagate crystal 8 tusis_1 Crystal Reports 0 May 12th, 2007 11:45 AM
Crystal Report shah rukh hasan VS.NET 2002/2003 0 April 6th, 2005 02:01 AM
Crystal report help Samk Crystal Reports 2 October 13th, 2004 10:11 AM
Error While printing report (Crystal report) vikaspaweb Pro VB 6 0 March 8th, 2004 09:53 AM





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