Wrox Programmer Forums
| Search | Today's Posts | Mark Forums Read
Crystal Reports General discussion about Crystal Reports. For discussions specific to the book Professional Crystal Reports for VS.NET, please see the book discussion forum for that book.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Crystal Reports 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
  #1 (permalink)  
Old February 7th, 2005, 12:28 PM
Authorized User
 
Join Date: Dec 2004
Location: flushing, ny, USA.
Posts: 80
Thanks: 0
Thanked 0 Times in 0 Posts
Default Sub report issue

Hi,
My main report look like this
page1

PH - Animal# test Oper#
Detials 12 test1 1
         13 test2 1
         14 test3 1

PF - Oper#: 1 = User1, 2 = User2


page2

PH - Animal# test Oper#
Detials 1 test1 1
         2 test1 1
         3 test1 2

PF - Oper#: 1 = User1, 2 = User2

My question here is, in page 1 u have only Oper# 1 so in report, near page footer it should show only
Oper#: 1 = User1

I am getting this info aboutt the operator through a sub report.

Thanks,
Kavitha.
  #2 (permalink)  
Old February 9th, 2005, 07:50 AM
Authorized User
 
Join Date: Jul 2004
Location: chennai, tamilnadu, India.
Posts: 68
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to aravwind Send a message via Yahoo to aravwind
Default

Declare a global variable and assign the values in that variable and display in the footer.
  #3 (permalink)  
Old February 9th, 2005, 11:35 AM
Authorized User
 
Join Date: Dec 2004
Location: flushing, ny, USA.
Posts: 80
Thanks: 0
Thanked 0 Times in 0 Posts
Default

i could figure it out from some help in other forums.
this is the solution.

In your main report, create two formulas:

//{@reset} to be placed in the page header:
whileprintingrecords;
shared stringvar x := "";

//{@accum} to be placed in the detail section:
whileprintingrecords;
shared stringvar x;
if instr(x,totext({table.OperNo},"000") = 0 then
x := x + totext({table.OperNo},"000") + ", "; //add as many zeros as digits in the highest operator number

Then in the subreport, place the Operator Number and the Operator Name field. Do not link the subreport to the main report. Instead go to the section expert in the subreport->details->suppress->x+2 and enter:

whileprintingrecords;
shared stringvar x;
instr(x,totext({table.OperNo},"000")) = 0

Make sure the page footer is tall enough to accommodate the maximum number of results per page.


Similar Threads
Thread Thread Starter Forum Replies Last Post
Report Issue ghall202 Access VBA 3 January 4th, 2008 09:27 AM
Matrix report issue aranjan BOOK: Professional SQL Server Reporting Services ISBN: 0-7645-6878-7 0 February 4th, 2007 02:42 AM
V V V Urgent::Crystal report format issue narayanark2003 Crystal Reports 0 July 6th, 2006 07:58 AM
Sub report shared prob issue kondapally Crystal Reports 0 May 12th, 2005 10:46 AM
Sub Report Issue bjoneskc01 BOOK: Professional SQL Server Reporting Services ISBN: 0-7645-6878-7 1 January 21st, 2005 11:26 AM





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