Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7012691
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T22:17:18+00:00 2026-05-27T22:17:18+00:00

I have a crystal report in my asp.net web application which has a lot

  • 0

I have a crystal report in my asp.net web application which has a lot of report parameters (about 15). Previously I was using querystring to pass them but it was being unsecure.

Now I am mapping all parameters to a Hashtable, storing them in session & passing to the report viewer. Now If user opens multiple instance of reports in different browser tabs, the session values get messed up. When I navigate pages, wrong reports are displayed.

Please advise me a good method to pass my parameters to report.

Damien.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T22:17:19+00:00Added an answer on May 27, 2026 at 10:17 pm

    How about creating a simple DTO for storing all report parameters. Save this DTO in session and access in report viewer page where your viewer control resides.

    To cross over the session issue when user opens multiple instances in browser, you can do a simple trick. When user provides parameter, and clicks on “Show Report”, at that point create a guid, store value inside the session using key as this guid, and pass this guid as query string parameter to your report viewer page. This way each instance of report viewer page is aware which session value to be brought out.

    Something like this

    public class AttendanceDTO 
    { 
      public int EmployeeId {get;set;} 
      public string Month {get;set;}
    }
    

    And then in your “Report parameter page”

          /* JUST NOTEPAD CODE, SYNTAX MIGHT VARY */ 
        protected override ShowReport_Click(object sender, EventArgs e) 
                {
                   string guid = new Guid();
                    AttendanceDTO dto = new AttendanceDTO() 
                    { EmployeeId = txtEmployee.Text;
                    Month = txtMonth.text
                };
                session[guid] = dto;
                Response.Redirect("ReportViewer.aspx?Guid=" + guid);
                }
    

    And then inside your Report Viewer Page

    string guid = Request.QueryString["Guid"]; //Null check etc..
    AttendanceDTO dto = (AttendanceDTO) session[guid];
    //Provide dto values as parameters to your report viewer control and then clean the session
    

    [You would need to make sure that you clear out the respective session value after you get it used.]
    [Above code is just from notepad to give you an idea. On top of this you can bring more innovation]

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have created ASP.net Web application which uses Crystal Report to show reports. Now
I have a Crystal Report used in an ASP.NET web application that I've just
I have created reports using Crystal Reports in my asp.net application(vb). It was fine.
I have Finished Designing my first Crystal Report using ASP.NET, I am Providing user
I have written an web application in VS2010 ASP.net C#, to display Crystal reports.
I have built a web page which contains a Crystal Report built using the
I have an asp.net (2.0) page with a crystal report viewer. I use the
I have built a Crystal Report in VS2008 for an asp.net c# site. I
I have a web application written in C#/ASP.Net and the backend DB is Oracle.
I am trying to add crystal report viewer in ASP.NET 3.5 application, but its

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.