Results 1 to 8 of 8

Thread: Reports using CR9

  1. #1

    Thread Starter
    PowerPoster Simply Me's Avatar
    Join Date
    Aug 2003
    Posts
    2,748

    Reports using CR9

    I have this code to view my report. Im concerned with the time it takes to load the report when i view it. I have more or less ten pages of report in short bond paper. Is there any solution or alternative to using crystal report?

    VB Code:
    1. Private Sub Form_Load()
    2.   Call openConnection
    3.   Me.Left = 2640
    4.   Me.Top = 325
    5.  
    6.   sSQL = "SELECT Code, ProductDescription,Quantity,Reorder FROM Tblstocks"
    7.  
    8.   Set oRsStocks = New ADODB.Recordset
    9.   Set oRsStocks = oConn.Execute(sSQL)
    10.   Set oApp = New CRAXDRT.Application
    11.   Set oReport = oApp.OpenReport(App.Path & "\Inventory.rpt", 1)
    12.   oReport.Database.SetDataSource oRsStocks, 3, 1
    13.   CRViewer91.ReportSource = oReport
    14.   oReport.DiscardSavedData 'to refresh the data
    15.   CRViewer91.ViewReport
    16.  
    17. End Sub
    Last edited by Simply Me; Jul 13th, 2006 at 04:01 AM.
    To give is always to be NOBLE...
    To received is always to be BLESSED....
    Each day strive to be NOBLE
    Each day strive to be BLESSED

    If this post has helped you. Please take time to rate it.

    >=|+|=< Simply Me >=|+|=<

    ----------------------------------------
    Connection Strings | Number Only in Textbox | Splash Screen with Progress Bar | Printing to 1/2 of perforated bond paper |
    Freeze 2005 DataGridView Column

  2. #2
    PowerPoster
    Join Date
    Feb 2006
    Location
    East of NYC, USA
    Posts
    5,691

    Re: Reports using CR9

    Quote Originally Posted by Simply Me
    Is there any solution or alternative to using crystal report?
    If you meant "Is there any practical solution or alternative to using crystal report?", it depends on how complex your report is. You can always print line by line with the Printer object.
    The most difficult part of developing a program is understanding the problem.
    The second most difficult part is deciding how you're going to solve the problem.
    Actually writing the program (translating your solution into some computer language) is the easiest part.

    Please indent your code and use [HIGHLIGHT="VB"] [/HIGHLIGHT] tags around it to make it easier to read.

    Please Help Us To Save Ana

  3. #3

    Thread Starter
    PowerPoster Simply Me's Avatar
    Join Date
    Aug 2003
    Posts
    2,748

    Re: Reports using CR9

    Quote Originally Posted by Al42
    If you meant "Is there any practical solution or alternative to using crystal report?", it depends on how complex your report is. You can always print line by line with the Printer object.
    I want the user to have a view of what is to be printed before printing. The columns to be printed are Code, Product Description, Quantity, and Reorder. The pages that will be printed mostly like will from 1-15.

    I'm already using the printer object except with this problem being posted here.
    To give is always to be NOBLE...
    To received is always to be BLESSED....
    Each day strive to be NOBLE
    Each day strive to be BLESSED

    If this post has helped you. Please take time to rate it.

    >=|+|=< Simply Me >=|+|=<

    ----------------------------------------
    Connection Strings | Number Only in Textbox | Splash Screen with Progress Bar | Printing to 1/2 of perforated bond paper |
    Freeze 2005 DataGridView Column

  4. #4

    Thread Starter
    PowerPoster Simply Me's Avatar
    Join Date
    Aug 2003
    Posts
    2,748

    Re: Reports using CR9

    bump
    To give is always to be NOBLE...
    To received is always to be BLESSED....
    Each day strive to be NOBLE
    Each day strive to be BLESSED

    If this post has helped you. Please take time to rate it.

    >=|+|=< Simply Me >=|+|=<

    ----------------------------------------
    Connection Strings | Number Only in Textbox | Splash Screen with Progress Bar | Printing to 1/2 of perforated bond paper |
    Freeze 2005 DataGridView Column

  5. #5

    Thread Starter
    PowerPoster Simply Me's Avatar
    Join Date
    Aug 2003
    Posts
    2,748

    Re: Reports using CR9

    Huh? nothing still
    To give is always to be NOBLE...
    To received is always to be BLESSED....
    Each day strive to be NOBLE
    Each day strive to be BLESSED

    If this post has helped you. Please take time to rate it.

    >=|+|=< Simply Me >=|+|=<

    ----------------------------------------
    Connection Strings | Number Only in Textbox | Splash Screen with Progress Bar | Printing to 1/2 of perforated bond paper |
    Freeze 2005 DataGridView Column

  6. #6
    PowerPoster
    Join Date
    Feb 2006
    Location
    East of NYC, USA
    Posts
    5,691

    Re: Reports using CR9

    You could write your own viewer (there's code for that on various VB sites), but I doubt it would run much faster than Crystal's viewer.

    Two things I can suggest:

    1) Save the report (in Crystal) without saving the data. Then you don't need oReport.DiscardSavedData. It might make it a little faster.

    2) Look into using .ttx files and disconnected recordsets.
    The most difficult part of developing a program is understanding the problem.
    The second most difficult part is deciding how you're going to solve the problem.
    Actually writing the program (translating your solution into some computer language) is the easiest part.

    Please indent your code and use [HIGHLIGHT="VB"] [/HIGHLIGHT] tags around it to make it easier to read.

    Please Help Us To Save Ana

  7. #7

    Thread Starter
    PowerPoster Simply Me's Avatar
    Join Date
    Aug 2003
    Posts
    2,748

    Re: Reports using CR9

    I dont get what you mean in "Save the report without saving the data.

    I have no idea yet on using .ttx and disconnected recordsets. Any sample code please?
    To give is always to be NOBLE...
    To received is always to be BLESSED....
    Each day strive to be NOBLE
    Each day strive to be BLESSED

    If this post has helped you. Please take time to rate it.

    >=|+|=< Simply Me >=|+|=<

    ----------------------------------------
    Connection Strings | Number Only in Textbox | Splash Screen with Progress Bar | Printing to 1/2 of perforated bond paper |
    Freeze 2005 DataGridView Column

  8. #8

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width