Solved

Textbox containing a date expression changes in snapshots ?

Posted on 2008-06-20
1
434 Views
Last Modified: 2013-11-05
Hello,

My report contains a TextBox with an expression "=Now()" in the Page Header
in order to display the date and time the report was generated.

Now, when I open a snapshot of the report the value in the TextBox changes
to the current date and time, instead of preserving the value that was there
at the time the snapshot was generated.

I thought snapshots were static.

1. What exactly remains static for snapshots ?

2. Can or do parameters also change ? The reason I am asking is because I am
also displaying the paraemter values in the Page Header and I don't want
those values to change.

3. Is there a workaround ? I would like to preserve the date and time and I
don't want it to change every time someone generates the report from the
snapshot.

4. I also have two other textboxes on the Page Header which are VB.NET code expression which calculate dates. Will these change ?

Thank you for your help !
0
Comment
Question by:LiorRon
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 13

Accepted Solution

by:
rickchild earned 250 total points
ID: 21844805
1.  The following is stored as part of a snapshot:

- Data result set
- Report Definition (the code in the .rdl)
- Parameter Values
- Embedded objects such as images

2. Regarding parameters see the quote below from this link, but it looks like the parameters do not change.

http://technet.microsoft.com/en-us/library/aa274411(SQL.80).aspx

You can create a snapshot for a report using one set of parameter values.
If a parameterized report supports multiple values for a single parameter (for example, an EmployeeID parameter that takes an employee-specific value), only one of those values is stored with the snapshot.
If a user requests the report using a different parameter value, the value is ignored.
The snapshot that the user sees is based on the parameter value that is stored with the snapshot.

3. You could try using this instead of =Now()

=Globals!ExecutionTime

Also if that doesn't work the date and time of snapshot is stored with the snapshot in the database, as you can see the "When Run" in report manager next to the report.  Not sure exactly where this is stored, but a workaround may involve running a trace, opening that page to see which Stored Procedure is used by the server to pull this date, and using it in the report as a data source.

4. Unsure sorry, may need to test.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I recently went through setting up a JasperReports Server using the AWS EC2 instance, and this article will cover some basic administration tasks I had to perform.
From implementing a password expiration date, to datatype conversions and file export options, these are some useful settings I've found in Jasper Server.
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial
Suggested Courses

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question