Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

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

Printing from Crystal Reports 9 within MS Access

In previous versions I used to compile reports for distribution.   These compiled reports were accessed via MS Access forms and allowed run-time perameters.   Version 9 does not allow this.
Is there a way in which I can achieve a similar result, and if there is what files would also need to be ditributed.
I urgently need to get help on this as my job depends on it (I recommended an upgrade to 9 and so far as the boss is concerned, it doesn't work)
Perhaps there is a third party product that could do the job.
Bring back the compiler !!!

Many thanks

Peter Stevens

0
Fourte
Asked:
Fourte
  • 7
  • 4
  • 3
  • +3
1 Solution
 
mnyeCommented:
Peter,

What about export formats? PDF, Excel, RTF, HTML?

Also, what version of 9 did you buy, Professional, Developer or Advanced? If you have any version other than Professional than you have lots of options to automate this process utilizing a web, VB or .Net application.

hth
matt
0
 
FourteAuthor Commented:
Version was Professional
I need to do a straightforward print but with option of inserting run-time parameters

Peter
0
 
mnyeCommented:
Peter,

You'll need Developer.  That includes the Crystal Runtime Engine, RAS (Reports Application Server)  and access to the API which is what you need to insert runtime parameters (http://www.crystaldecisions.com/products/crystalreports/editions.asp).

hth
matt
0
Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

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.

 
wsteegmansCommented:
Seems that you have the wrong version (Developer or Advanced Edition can):

Fragment from CR-Site:

Integrate reports into thick-client applications

Crystal Reports Developer and Advanced Editions provide high productivity report design technology and powerful developer tools for integrating reporting capabilities into thick-client applications. Two key licensing rights apply:

As with previous versions of Crystal Reports, you can integrate 750+ royalty-free report viewing, printing and modification APIs into thick-client applications and deploy and/or redistribute your applications at no extra cost (known as "free runtime"). While there is no additional charge for redistributing these APIs, your distribution of the files is subject to terms and conditions contained in the Crystal Reports 9 License Agreement (ZIP – 44 KB).
Crystal Reports 9 also offers a powerful set of report creation APIs to let end users create and modify reports from within your thick-client application. If you use these APIs, you must purchase a Report Creation API License for each named user that you deploy and/or redistribute your application to.

Once, I used CR 9 Advanced in combination with a VB-Program. Created a package with also the CR Runtime, and it just worked fine!
0
 
FourteAuthor Commented:
Thanks for the advice but I am on a shoestring and have spent out so much (personally) that I am now looking for a low cost solution (if there is one)
Crystal Decisions Technical Support  give an example - rdc_vba.exe which is exactly what I need.   This Visual Basic application is for use with version 8.5 and higher of Crystal Reports.   Unfortunately it is written in VBA and is run-time only
Any comments how this could be re-written - or by whom?   There would be a very good market for such a utility as you know.

Peter
0
 
mnyeCommented:
RDC is the older version of RAS. as far as I know you cant run CR 9 reports with the RDC you need RAS. If you want the runtime capability, you may have to shell out the extra money for Developer edition. sorry to be the barer of bad news.

good luck
matt
0
 
mlmccCommented:
Look here for some inexpensive viewers with the capability to do what you want.

http://www.kenhamady.com/bookmarks.html

mlmcc
0
 
EwaldLCommented:
mnye, there is no problem whatsoever to view a cr 9 report with the rdc. just update the references from
craxdrt.dll to craxdrt9.dll
and crviewer.dll to crviewer9.dll

so Fourte's best bet would be to write his (her?) own application using the rdc using cr 9 developer or advanced.

Fourte, let us know if you have any questions on this!
0
 
FourteAuthor Commented:
my problem is that I am not knowledgeable enough to attempt to write something like this.
If someone would be prepared to have a look at the example and write a module to do the job I would be prepared to pay (a small amount)
0
 
EwaldLCommented:
maybe these steps will give you a good headstart. it's a very basic example without any error checking though
Also the following could be helpful for you.
http://support.crystaldecisions.com/communityCS/TechnicalPapers/rdc9_tutorial.pdf.asp
http://support.crystaldecisions.com/communityCS/TechnicalPapers/rdc9_browser.exe.asp
http://support.crystaldecisions.com/communityCS/TechnicalPapers/rdc9_deployment.pdf.asp
http://support.crystaldecisions.com/communityCS/TechnicalPapers/apps_rdc.pdf

- Open VB 6
- "File" -> "New Project" -> "Standard Exe"
- "Project" -> "Add Form" -> "Form"
- "Project" -> "References" -> "Crystal Reports 9 ActiveX Designer Runtime Library" -> "OK"
- "Project" -> "References" -> "Microsoft Common Dialog Control" -> "OK"
[do NOT select "Crystal Reports 9 ActiveX Designer Design and Runtime Library"]
- "Project" -> "Components" -> "Controls" -> "Crystal Reports Viewer Control 9" -> "OK"
- "View" -> "Toolbox"
- Place the "CRViewer9" from the toolbox onto "Form2"
- Place a textbox and 2 buttons on Form1
- Place the "Common Dialog" form the toolbox onto "Form1"
- Use this code for Form1
Option Explicit
Dim crApplication As New CRAXDRT.Application
Dim crReport As CRAXDRT.Report

Private Sub Form_Load()
  Text1.Text = ""
  Command1.Caption = "Select Report"
  Command2.Caption = "View Report"

  CommonDialog1.InitDir = App.Path
  CommonDialog1.Filter = "Crystal Report Files (.rpt)|*.rpt"
 
  Form2.CRViewer91.EnableExportButton = True
End Sub

Private Sub Command1_Click()
  CommonDialog1.ShowOpen
  Text1.Text = CommonDialog1.FileName
End Sub

Private Sub Command2_Click()
  Set crReport = crApplication.OpenReport(Text1.Text)
  crReport.DiscardSavedData
  Form2.CRViewer91.ReportSource = crReport
  Form2.CRViewer91.ViewReport
  Form2.WindowState = vbMaximized
  Form2.Show
End Sub

Private Sub Form_Unload(Cancel As Integer)
  Set crReport = Nothing
  Set crApplication = Nothing
End Sub

- and this code for Form2
Option Explicit

Private Sub Form_Resize()
  CRViewer91.Top = 0
  CRViewer91.Left = 0
  CRViewer91.Width = ScaleWidth
  CRViewer91.Height = ScaleHeight
End Sub
0
 
FourteAuthor Commented:
Now that's what I call realy good help !!

I have never gone so far as to use VB in CR so I have got to learn how to do so, and if I can find a way of inserting the facility to select a report file it would be the solution.

Am now going to research the sites you gave me.

If I can make a small donation please e-mail peterstevens@btconnect.com

Thanks for everything EwaldL, mlmcc, mnye and wsteegmans, I didn't know such good help was available - now I can perhaps start to learn through your site, although having had two strokes that damaged my brain I find it very hard going.

Thanks, thanks, thanks !!!
0
 
EwaldLCommented:
no worries fourte, we are glad to help! the above instructions i had posted already allow the end user to select a report file. so hopefully it will achieve what you are looking for!
0
 
FourteAuthor Commented:
Hi EwaldL
Thanks for previous help - BUT!!
I do not have VB (any version) could you tell me how I could put the code directly into Access?
Your help is very much appreciated
0
 
FourteAuthor Commented:
In the absence of EwaldL is there any kind person who can help me with putting the code directly into Access?
I am at my wits end and ready to end it all with a rusty safety razor if I can't get a good nights sleep tonight

Thanks to all
0
 
mnyeCommented:
from Access click on "Reports" section, then click "Create report in Design view", then right click on the new report and select "Build Expression",  select "Code Builder" fro mthe resulting pop up box and from there you can paste in your code.  for better help with access you should post a question in the Access forum.

hth
matt
0
 
FourteAuthor Commented:
Cheers Matt
0
 
Jimby_AusCommented:
I just tried the same call to the RDC in VB.Net, the same thing happens - nothing.

        Dim moCrxApp As New CRAXDRT.Application()
        Dim moCrxView As New CRVIEWER9Lib.CRViewer9()

        Dim objReport As New CRAXDRT.Report()

        objReport = moCrxApp.OpenReport("C:\Temp\TestReport.rpt", 1)

        moCrxView.ReportSource = objReport
        moCrxView.ViewReport()

Is the RDC supposed to be licensed?  How does it know its registered?
0
 
Jimby_AusCommented:
arghh, wrong window :)
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

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.

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