value of variable with an index from delphi to the script

edited 3:42PM in FastReport 4.0
I use the form.reportgetvalue procedure in delphi to pass a variable value from my delphi project to de fastreport script.
In my FR script I defined the following loop:

<!--fonto:Courier New--><span style="font-family:Courier New"><!--/fonto-->for i := 0 to 9 do
begin
mem := Tfrxmemoview(findobject('mem' + inttostr(i));
....
...
if mem <> nil then
mem.text := <variable_i>; //?? // Print the value of variable 'variable i' , (thus: variable1 for mem1, variable2 for mem2,....);
end;<!--fontc--></span><!--/fontc-->

How do I get the integer i into my variablename <variable_i>?

I tried: <variable + inttostr(i)>
<'variable' + inttostr(i)>

Comments

  • gpigpi
    edited 3:42PM
    Try

    mem.text := '<variable_' + inttostr(i) + '>';
  • edited 3:42PM
    Thanks for the hint, it helped me to find the following solution:

    mem.text := '[variable_'+inttostr(i)+']';

Leave a Comment