Showing posts with label refresh. Show all posts
Showing posts with label refresh. Show all posts

Tuesday, March 20, 2012

Crystal Reports - Refresh Problems

Using VB6. New to Crystal. Our app opens a report and shows it. When
we change the underlying database, every time the report is viewed,
even if no fields that affect the report are changed, report was not
opening at all. im calling report from my VB application with few
parameters.

When im opening the report manually from Report Designer (8.5 Dev
edition) and using the option VERIFY DATABASE, its showing the message
("The database is now up to date"). and report working properly and
update info is ther in reports.

How can I get Crystal to just do it automatically? How can I do it in
code so end users see their reports despite changes in the database?

(i'm using VB 6.0, Ms Access 2000 and Crystal Report 8.5 Dev edition)Hi Sekhars

try this out
1. set the database property at form load event.
CrystalReport1.Database(0)="C:\mydb.mdb"
CrystalReport1.ReportFilename="c:\Report.rpt"

2, On the button_Click event
CrystalReport.Action=1

Try this out if it works rate me|||Hi Fundooo,

I'm using crystal report control to call my report created seperatly in report designer. im calling my report from vb application.

in your reply you suggested to use as below

crystalreport1.database(0) = "c:\mydb\test.mdb"
crystalreport1.reportfilename = "C:\myrept\test.rpt"

but im not able get DATABASE method, crystalreport1.database not working with me..... saying "AUTOMATION FAILED/ NOT SUPPORTED" -

still im fighting with this problem.....

regards
Sekhar|||do you know how to declare and instantiate a report object in VB??
eg in general declarations at top of form code area:
Dim objPrintApp As CRAXDRT.Application
Dim objReport As CRAXDRT.Report

and then, in a sub or function:
Set objPrintApp = New CRAXDRT.Application
Set objReport = objPrintApp.OpenReport(strReportSourcePath & strSourceFile)

If you're getting an automation error, you probably haven't done your declare and instantiation properly.

dave|||This is my Code
-------

Rem Reference to Crystal Report Object.
Rem DDReport = Crystal Report Object Name
Rem All required properties are set to DDReport object.

Private sub CmdPrt_Click()

On Error GoTo errhand

DDReport.ReportFileName = "c:\Reports\DDRpt.rpt"
DDReport.PrintReport
DDFavList = False
Unload Me
Exit Sub
errhand:
DDFavList = False
MsgBox Err.Description, vbInformation, "Error"
Exit Sub
end sub

Monday, March 19, 2012

Crystal report refresh

Hi All i'm working in crystal report 8.5 with visual basic 6. All reports are working well only problem when we open any report. coz when we open report it take much time to show data on report. mean its processing speed is very slow. i wants when i open report, with in few seconds it shows all record, but this can be huge record. mean i wants to make it more efficient, then usual.
if i convert these reports into crystal report 10 from 8.5, how it will be....... mean it will increase its efficiency or not.
plz tell me if any one knows abt it.

mushiHow many data does the table have?

Wednesday, March 7, 2012

Crystal Alerts but in Reporting services

In Crystal Reports you can setup Alerts to alert you to a certain criteria when ever you refresh the report..

Is this possible within Reporting services?

If so how do you set them up?

Thanks

I'm not sure how well it would work for you because I am not sure of your criteria, but you could add a reference to System.Windows.Forms and then add code to the code window that displays a message box if certain criteria is met. If you can give me an example of your criteria I can try to give you an example.

Simone

|||

Hi Simone

Its a really simple criteria

In crystal I have setup

Sum ({@.Euro to Sterling GP}, {ACCOUNT_NAME}) < 25.00

Thanks for your help

|||

This is somewhat of a hack, but it should work:

Add a reference to System.Windows.Forms
In the code window, add a function similar to the following:

function ShowMessage(value as decimal) as decimal

If value < 25 then System.Windows.Forms.MessageBox.Show("Your Message")
ShowMessage = value
End function

In the field where you have the summary:


Add the following expression:
=Code.ShowMessage(Sum(FieldToSum,ScopeName))

I hope this helps. I've never used alerts in Crystal, but this will show a message box. You could also change the color of the field by using an expression if this is a better option for you. You may want to set a variable to only show the message once if multiple values are < 25.

Simone

|||This is not possible with Reporting Services. If you use the ReportViewer control you can trap events but not down to the data changes. With web reporting and rendering the report in a frame, you may try to get try to get a reference to the field but to track the change you need to track the old value so it will hairy.|||Thanks guys for all your help|||

I see that this only works in the development studio. I wondered how it would behave when displayed through IIS.

Thanks for the explanation.