jasper reports - JasperReports: using variable in variable's expression -
i using jaspersoft studio , trying set variable value of variable (well actually, need sum of 2 variables in variable) so have 2 variables, , b. need put in b. whenever use textfield output a, works fine. if in variable b, put ($v{a}), , try print b, null. does have clue why happens? report x contains subreport y returns variable <returnvalue subreportvariable="expenditures_total_var" tovariable="expenditures_total_var" incrementerfactoryclass=""/> (note same variable name in both reports) report x contains variable <variable name="stotal_var" class="java.lang.double" calculation="sum"> <variableexpression><![cdata[$v{expenditures_total_var}]]></variableexpression> </variable> this works: <textfield> <reportelement x="120" y="1" width="70" height="30" uuid="f0e81b0f-ddd3-4f31-9711-cfdeb64f36b2"/...