|
-
Sep 12th, 2001, 10:33 PM
#1
Thread Starter
Hyperactive Member
Another Crystal Report Question
When I print my address labels using Crystal Reports I want to preview before printing. That part is easy enough but I want the preview to always default to 85%.
Any ideas how I can do this.
I've swithched from Crystal Reports 4.6 which came with VB6 to Crystal Reports 6.0 which was just given to me this afternoon.
Any help here would be most appreciated.
Thanks,
Rev. Michael L. Burns
-
Sep 13th, 2001, 04:39 AM
#2
Fanatic Member
There is a zoom method or similar you can set before opening the report. Can't remember exactly what it is though.
Gary Lowe 
VB6 (Enterprise) SP5
ADO 2.6
SQL Server 7 SP3
OK I know my spelling and grammer is crap so don't quote me on it!
To err is human to take the P! is only natural !!
Click on the top section of image for Marcus Miller website and bottom section of image for 'Run For Cover' sound clip

-
Sep 13th, 2001, 07:28 AM
#3
Gary.Lowe is referrring to the PageZoom method. To use it, say:
CrystalReport1.PageZoom 75 (or whatever)
NOTE: This command MUST FOLLOW the Action method, i.e.:
This does not work
CrystalReport1.PageZoom 75
CrystalReport1.Action = 1
This does work
CrystalReport.Action = 1
CrystalReport.PageZoom 75
-
Sep 13th, 2001, 08:31 AM
#4
Thread Starter
Hyperactive Member
Gary.Lowe,
Thanks. I had already tried the Zoom but couldn't get it to work. The message from Hack explained why.
Hack,
Your solution works when using my earlier version of Crystal Reports but I am now using the Crystal Reports 6 Viewer which is added to the project when I add the Crystal Reports 6.0 ActiveX Designer.
I have to do a similar procedure to the one you gave but I initially get an error. Here is what I have in my form load event:
CRViewer1.ReportSource=Report
CRViewer1.ViewReport
CRViewer1.Zoom (85)
When the form loads I get a dialog Box stating that I had a Runtime error as follows.
RunTime Error "-2147467259(80004005)
The Control is Busy downloading Data
If I click the Debug button on the Dialog Bpx and then clcik start again, begining at the location of the error (which is on the Zoom statement) the program continues and comes up with the report at 85%.
ANy Ideas.
Rev. Michael L. Burns
-
Sep 13th, 2001, 08:40 AM
#5
Fanatic Member
Try it this way
CRViewer1.ReportSource=Report
CRViewer1.Zoom (85)
CRViewer1.ViewReport
I used to get this error if I tried to use a method after the .ViewReport
Gary Lowe 
VB6 (Enterprise) SP5
ADO 2.6
SQL Server 7 SP3
OK I know my spelling and grammer is crap so don't quote me on it!
To err is human to take the P! is only natural !!
Click on the top section of image for Marcus Miller website and bottom section of image for 'Run For Cover' sound clip

-
Sep 13th, 2001, 09:23 AM
#6
Thread Starter
Hyperactive Member
Gary,
When I move it to just before the ViewReport it is ignored and always comes up at 100%
Pastor Mike
-
Sep 13th, 2001, 09:31 AM
#7
Fanatic Member
Hmm not too sure then Rev
I know you tend to get that error because the .ViewReport is still populateing the report.
I havn't got CR here so I can't try it myself. Maybe putting a DoEvents after may stop that although it's not ideal.
Gary Lowe 
VB6 (Enterprise) SP5
ADO 2.6
SQL Server 7 SP3
OK I know my spelling and grammer is crap so don't quote me on it!
To err is human to take the P! is only natural !!
Click on the top section of image for Marcus Miller website and bottom section of image for 'Run For Cover' sound clip

-
Sep 13th, 2001, 09:59 AM
#8
I don't have 6.0, so I'm not sure what the problem is.
Take a look a the developers help file (developr.hlp), and see what it says about PageZoom.
This file is in my c:\program files\seagate crystal reports folder.
If you don't find it there, then just do a drive wide search using Windows Find.
-
Sep 13th, 2001, 10:17 AM
#9
Thread Starter
Hyperactive Member
Gary,
Placing a DoEvents between the ViewReport and the Zoom does the trick.
Pastor Mike
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|