Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 1.0 and 1.1 > ASP.NET 1.0 and 1.1 Basics
Password Reminder
Register
| FAQ | Members List | Search | Today's Posts | Mark Forums Read
ASP.NET 1.0 and 1.1 Basics ASP.NET discussion for users new to coding in ASP.NET 1.0 or 1.1. NOT for the older "classic" ASP 3 or the newer ASP.NET 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.0 and 1.1 Basics 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 October 14th, 2004, 03:56 AM
Authorized User
 
Join Date: Jun 2004
Location: , , .
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
Default drystal reports with asp.net

I am using Visual Studio Pro and have built in a Crystal Report
that is viewed under my asp.net webpage.

Question : I need to be able to pass the report a parameter
from the webpage. How can I programatically add a variable to my report that can be set by the webpage that creates the report?

I want to format my report based on the value of this variable.

Chhers.


  #2 (permalink)  
Old October 14th, 2004, 04:02 AM
Friend of Wrox
 
Join Date: Jun 2004
Location: Chennai, Tamil Nadu, India.
Posts: 449
Thanks: 0
Thanked 1 Time in 1 Post
Send a message via MSN to r_ganesh76
Default

you can create a parameter in your report and set the value of this parameter through code using the SetParameterValue method of the ReportDocument Class

   ReportDocument cr = new ReportDocument();
   cr.Load(strReportPath);
   cr.SetDataSource(DS.Tables["Customers"]);
   cr.SetParameterValue("StartDate", strMyParmValue);
   CrystalReportViewer.ReportSource = cr;


Regards
Ganesh
 


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
ASP.NET 1.1,VB.NET,crystal reports, SQl server gvi Crystal Reports 1 September 11th, 2008 02:55 AM
reports in asp.net pradeep29 ASP.NET 1.0 and 1.1 Professional 3 May 31st, 2007 05:33 AM
ASP.Net with Crystal Reports jazzcatone ASP.NET 1.0 and 1.1 Basics 1 March 1st, 2006 01:11 AM
ASP.Net reports msrnivas .NET Web Services 0 April 12th, 2004 09:05 PM
Using Crystal Reports in ASP.NET jbenson001 ASP.NET 1.x and 2.0 Application Design 2 November 18th, 2003 10:52 AM



All times are GMT -4. The time now is 07:51 AM.


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