How to get memo text or value at run time
Hi
I'm using Delphi XE3's FR4. I want to get the value shown by a memo, do a calculation on that value and output the new calculation to another memo when the report is run.
But if I put the following code into any number of events (ClickObject, Preview etc..) . . . .
var srce, dest:TfrxMemoView;
begin
dest := TfrxMemoView(rpt_DayEnd.FindComponent('Memo35'));
srce := TfrxMemoView(rpt_DayEnd.FindComponent('Memo27'));
if (srce <> nil) and (dest <> nil) then
begin
dest.Text := performCalculationRequiringAFloatingPointValue(strtofloat(srce.value));
end;
end;
. . . . . . the srce.value shows '' and srce.text shows the formula within Memo27 from which the value is calculated.
How can I achieve what I'm trying to do here? Is it at all possible?
Thanks
Regards
Steve
I'm using Delphi XE3's FR4. I want to get the value shown by a memo, do a calculation on that value and output the new calculation to another memo when the report is run.
But if I put the following code into any number of events (ClickObject, Preview etc..) . . . .
var srce, dest:TfrxMemoView;
begin
dest := TfrxMemoView(rpt_DayEnd.FindComponent('Memo35'));
srce := TfrxMemoView(rpt_DayEnd.FindComponent('Memo27'));
if (srce <> nil) and (dest <> nil) then
begin
dest.Text := performCalculationRequiringAFloatingPointValue(strtofloat(srce.value));
end;
end;
. . . . . . the srce.value shows '' and srce.text shows the formula within Memo27 from which the value is calculated.
How can I achieve what I'm trying to do here? Is it at all possible?
Thanks
Regards
Steve
Comments
Thanks
Steve