Adjust memo width at runtime
Need help being able to adjust the width of a memo (text) at runtime. as you can see in the screen/form images below, depending on if the image is to be shown the memo.width needs to be adjusted. By default i have the memo set to the full width. how do i set this at runtime?
I have tried ( fr3x4BeforePrint, & fr3x4GetValue ) both methods:
Method 1: TfrxMemoView(fr3x4.FindObject('lblMaterial')).Width := 100;
Method 2: Var
Memo1 :TfrxMemoView;
Memo1 := fr3x4.FindObject('lblMaterial') as TfrxMemoView;
Memo1.Width := 100;
But i get an error when trying to run the report
thanks,
Comments
This work for me. Set the Align property of the label ti baWidth. When the image on the right is visible the label stop there, when is not visible it use all the width of the band.
Another way could be to use the script of FR, for example, using the OnBeforePrint event of the label itself, or the OnBeforePrint of the underlying band
Awesome! Thanks,