Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

While exporting a report particular column misbehaves

Posted on 2014-01-20
9
Medium Priority
?
244 Views
Last Modified: 2014-01-25
I've a report in my windows application. The report works fine with in  my application. But when I export to PDF file the particular column (datetime column) is shown as #Error. When I export same report as Excel, the column shows value as #VALUE!

Have you come across this kind of issue earlier? If so, please do help me how to solve the issue. Please do assist!

Please note that two different RDLs are used for application and export option.

Thanks in advance.
0
Comment
Question by:Easwaran Paramasivam
[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
  • 4
  • 4
9 Comments
 
LVL 44

Accepted Solution

by:
AndyAinscow earned 2000 total points
ID: 39794541
Do other datetime columns work?
If the problem is with the datetime a workround would be to have it as a formatted string instead of the native type.
0
 
LVL 16

Author Comment

by:Easwaran Paramasivam
ID: 39794700
It works fine with other datetime columns. Moreover the column which shows wrong value do not contain NULL value. Please do suggest.
0
 
LVL 44

Expert Comment

by:AndyAinscow
ID: 39794815
Do the column names in the reports match exactly the column name in the source ?
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
LVL 16

Author Comment

by:Easwaran Paramasivam
ID: 39798020
=Convert.ToDateTime(IIF(IsNothing(Fields!LastPasswordDtm.Value),DateTime.MinValue,Fields!LastPasswordDtm.Value).ToString()).ToString().Replace(DateTime.MinValue.ToString(),string.Empty)

Open in new window

Above code helps me.
0
 
LVL 16

Author Comment

by:Easwaran Paramasivam
ID: 39799157
I've requested that this question be closed as follows:

Accepted answer: 0 points for EaswaranP's comment #a39798020

for the following reason:

While exporting the data the NULL validation should be handled correctly. Accepting as solution for tracing purpose and would be useful for others.
0
 
LVL 44

Expert Comment

by:AndyAinscow
ID: 39799158
>>Moreover the column which shows wrong value do not contain NULL value.

The above was from an earlier comment.
From the proposed solution
While exporting the data the NULL validation should be handled correctly

Something isn't correct.
0
 
LVL 16

Author Comment

by:Easwaran Paramasivam
ID: 39809113
I've requested that this question be closed as follows:

Accepted answer: 0 points for EaswaranP's comment #a39798020

for the following reason:

Accepting as solution for tracking
0
 
LVL 44

Expert Comment

by:AndyAinscow
ID: 39809114
Proposed solution is:
=Convert.ToDateTime(IIF(IsNothing(Fields!LastPasswordDtm.Value),DateTime.MinValue,Fields!LastPasswordDtm.Value).ToString()).ToString().Replace(DateTime.MinValue.ToString(),string.Empty)

which on contraction is:
=Convert.ToDateTime(...).ToString().Replace(DateTime.MinValue.ToString(),string.Empty)

which is resulting in a string.

See my first comment - you could convert to a string.
0

Featured Post

NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

Question has a verified solution.

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

Why is this different from all of the other step by step guides?  Because I make a living as a DBA and not as a writer and I lived through this experience. Defining the name: When I talk to people they say different names on this subject stuff l…
Performance in games development is paramount: every microsecond counts to be able to do everything in less than 33ms (aiming at 16ms). C# foreach statement is one of the worst performance killers, and here I explain why.
Via a live example, show how to shrink a transaction log file down to a reasonable size.
Via a live example, show how to setup several different housekeeping processes for a SQL Server.

715 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