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

  • Home
  • SEARCH
  • 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 8584461
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T21:46:46+00:00 2026-06-11T21:46:46+00:00

I have a console application in C# which works with crystal reports. I am

  • 0

I have a console application in C# which works with crystal reports. I am loading report (only once) using:

    static ReportDocument cryReportDocument = new ReportDocument();

    static void Main(string[] args)
    {            
        cryReportDocument.Load("reportLocation");
        ....
        //I am exporting about 20.000 .pdf files
        while(true)
        {
            ....
            //destianationPath is file location 
            ExportToPdf(destinationPath)
        }
    }

Then I am exporting this report to pdf file using:

    //Export pdf file
    static void ExportToPdf(string destianationPath)
    {                     
        cryReportDocument.SetDatabaseLogon("userName", "password", "Database", "");
        //Adding paremeters to report
        cryReportDocument.SetParameterValue(.., ..);    
        //This line consumes a lot of time now  
        cryReportDocument.ExportToDisk(CrystalDecisions.Shared.ExportFormatType.PortableDocFormat, destianationPath);
    }

I used this program before (about two or three days before) to export about 15.000 .pdf files and it worked very well. Exported one .pdf file in approximately less then one second. I changed nothing in my code but that line takes about 5 seconds to export one .pdf file. What can cause to this? Computer is the same, I have changed nothing. But it is not working properly. Can anyone help?

  • 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-06-11T21:46:47+00:00Added an answer on June 11, 2026 at 9:46 pm

    Could it be the database that is slow? (as requested by Adil)


    Additional info (hope you don’t mind):

    The ExportToDisk method causes crystal to actually execute the database query. The best test in this case would be to directly execute the query to see how long that takes. Adjust as necessary.

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

Sidebar

Related Questions

I have a c++ console application which I would like to publish using clickonce.
I have a console application which works perfectly in 32 bit machine. But I'm
i have a small console application which connects to outlook with using com. My
I have a console application which is parsing HTML documents via the WebRequest method
I have a console application which has target .NET 2.0 It is very short
I have a console application which can also open winform under certain conditions.Processing(its a
I have the sample console application which is supposed to be executed in the
I have a console application in which I want to write the name of
I have a console application from which I create a window. I can render
I have written very very simple console application which supports some command line options.

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.