Wrox Programmer Forums
|
BOOK: Professional Crystal Reports for VS.NET
This is the forum to discuss the Wrox book Professional Crystal Reports for Visual Studio .NET by David McAmis; ISBN: 9780764544033
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional Crystal Reports for VS.NET section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old January 20th, 2005, 08:30 AM
Registered User
 
Join Date: Jan 2005
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
Default Formatting Areas

I wish to programmatically suppress a group.

Accorinding to p296 of 2nd edition, the VB code is

myReport.ReportDefinition.Areas.Item(1).AreaFormat .EnableSuppress = True

in c#, as I type, it lets me get upto

myReport.ReportDefinition.Areas.

but then there is not an Item

What is the equivalent code?

 
Old January 20th, 2005, 11:31 AM
Registered User
 
Join Date: Jan 2005
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
Default

OK, so I have sort of worked out the code.

myReport.ReportDefinition.Areas[3].AreaFormat.EnableSuppress=true;

My detail section is Section3 and with above code, it no longer appears.

However, my group that i want to supress is Section8, but if I do 8 above, I get un unhandled exception - Invalid Section

 
Old January 20th, 2005, 01:22 PM
Registered User
 
Join Date: Jan 2005
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Right, I think I've got it

myReport.ReportDefinition.Areas[4].AreaFormat.EnableSuppress=true;

will turn off the 5th section from the top of the screen i.e. a zero based array

nothing to do with the actual section number displayed in the report i.e Section7 or whatever.

Anyone got any comments would be appreciated - in case there are better ways.






Similar Threads
Thread Thread Starter Forum Replies Last Post
newbie - grouping from different areas? wilgartw XSLT 5 October 30th, 2007 09:46 AM
Aligning two chart plot areas - simple but tricky! Alseikhan Excel VBA 0 March 20th, 2006 07:18 PM
Linking to specific areas in a new page CathyM BOOK: Beginning ASP 3.0 2 August 2nd, 2005 09:23 AM
Formatting Ben Access 3 February 28th, 2004 05:52 AM
Login Page going to 3 different management areas stacy Classic ASP Databases 1 January 21st, 2004 09:18 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.