cancel
Showing results for 
Search instead for 
Did you mean: 

Shared variables in Main report and its sub-reports?

Former Member
0 Kudos

Hi Experts

I wantto know how to use a shared variable in a main report and its subreports. I have create a shared variable in main report coding is given below.

whileprintingrecords;

shared numberVar inv_amt;

if doc_amt> 100000 then

inv_amt := inv_amt + doc_amt;

inv_amt

I placed this formula in detail section it works properly. now i want to show the last total value in sub report also How I can do this?

Regards

Gorge

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

HI Ance,

Create new Formula in Sub-Report with below code and put where you want to show the total.

shared numberVar inv_amt;

inv_amt;

Hope this will help u .

Rgds,

Premraj

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

As what I understand you want to get the total of the last record from detail section of the sub report?

Please explain further,

Regards,

Clint