Hi, getting confused about variables and searching the forum hasn't helped.
Working on CR8 to a SQL server.
I have a shared number variable where either 1 or 0 appears against an account code in the main report. I want to sum these to produce a total in the report footer. Here is some explanation of the reports: -
Sub-report: -
Linked by account to main report
//@VCOUNT
whileprintingrecords;
shared numbervar x:= if not isnull({@Account}) then 1 else 0;
Main Report: -
Grouped by account
My reset is in the group header
//@RESET
whileprintingrecords;
Shared Numbervar w:=0;
My variable is in the detail
//@COUNT
whileprintingrecords;
shared numbervar w;
I am happy that the reset and the visible 1 or 0 in the main report are correct but I cannot get a count total into the report footer - how does one do it?!?
Any help appreciated.
T
(I know you will probably say why not just have a record count if there is always going to be one record for each account; the answer is that the value of the variable can be 0 so I am looking to sum to show how many accounts are not in the sub report that are in the main report.)
Working on CR8 to a SQL server.
I have a shared number variable where either 1 or 0 appears against an account code in the main report. I want to sum these to produce a total in the report footer. Here is some explanation of the reports: -
Sub-report: -
Linked by account to main report
//@VCOUNT
whileprintingrecords;
shared numbervar x:= if not isnull({@Account}) then 1 else 0;
Main Report: -
Grouped by account
My reset is in the group header
//@RESET
whileprintingrecords;
Shared Numbervar w:=0;
My variable is in the detail
//@COUNT
whileprintingrecords;
shared numbervar w;
I am happy that the reset and the visible 1 or 0 in the main report are correct but I cannot get a count total into the report footer - how does one do it?!?
Any help appreciated.
T
(I know you will probably say why not just have a record count if there is always going to be one record for each account; the answer is that the value of the variable can be 0 so I am looking to sum to show how many accounts are not in the sub report that are in the main report.)