Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 966
  • Last Modified:

Crystal Report Export Problem

Dear Sir,
    I am using .net crystal reports on my machine.  i developed two reports.  the two reports are displaying correctly.  But in one report i am able to export the report correctly to the desired format.  but in the second report i am getting the error "input string not in correct format".  but the same code i used for the both reports.i.e., i copied the first reports code to the second reports code.

    The first report is in one page and the second report is in the dialog window.  and i passed all the parameter values and connection string values to the report along with the selection formula.

How can i over come this problem.
0
seshu123
Asked:
seshu123
  • 4
  • 2
1 Solution
 
seshu123Author Commented:
Actually the Error is Like this

Server Error in '/HATWebSite' Application.
--------------------------------------------------------------------------------

Input string was not in a correct format.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.FormatException: Input string was not in a correct format.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.  

Stack Trace:


[FormatException: Input string was not in a correct format.]
   System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer& number, NumberFormatInfo info, Boolean parseDecimal) +2753507
   System.Number.ParseInt32(String s, NumberStyles style, NumberFormatInfo info) +102
   System.Int32.Parse(String s) +20
   CrystalDecisions.Web.CrystalReportViewer.OnExport() +404
   CrystalDecisions.Web.CrystalReportViewer.RaisePostBackEvent(String eventArgument) +99
   System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +32
   System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +242
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3834

 


--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.42; ASP.NET Version:2.0.50727.42
0
 
Shay79Commented:
Hi

Have you tried verifying the database on the report thats not exporting?
0
 
mlmccCommented:
What code are you using to export the reports?

If you are passing date parameters they need to be DATE type or DATETIME type.  Crystal will not convert them for you.

mlmcc
0
Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
seshu123Author Commented:
Thanks Sir,
        i found the solution and i corrected my reports coding.


Thanks Once again for your valuable time
0
 
mlmccCommented:
What was the error?

mlmcc
0
 
seshu123Author Commented:
actually,
   I am calling the report in one window. But in asp.net i made a trick so that the window was a modal window.  for this i am calling the report window in another window.  so that  the database and the server information are missing.  after that i put some buttons on the top and i removed the crystal reports export and print dialog buttons.  


Then it was worked.


Thanks you sirs,
  thanks for your valuable time.
0
 
seshu123Author Commented:
ok Pls. Close the question.


Thanks & regards,
Seshu123
0

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

  • 4
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now