FastReport VCL for Delphi

i'm working with fast report VCL but it is my first time to work with it.
i don't have too much idea in fastscript.
in my script i want to select an item ID befor printing the information-detail on the report.
how can i do it? this is what i trying to do.

procedure OKOnClick(Sender: TfrxComponent);
var

ResultMsg : String;
Statement : String;
Affected : Integer;
ff:String;

begin

if Fortsetzen.ModalResult= mrNone then
showMessage('W?¤hlen Sie einen Formulartitel und Versuchen Sie noch mal')else
Report.Variables:= 'ComboBox1.Text';

if get('XXX')= 'BC0662' then // using to test ComboBox1
ShowMessage('FAUF Identify!!!!!!!!')
else
ShowMessage( <XXX> ); // show the data;

ff:='';

if InputQuery('FAUF-Input',please type the FAUF :',ff)=true then
begin
Statement:='SELECT * FROM Table_1 where FAUF=ff';

Here i want to select the Data set to print on the report ShowMessage('following wort was typed: '+ ff);

end else
begin
ShowMessage('the Data '+IntToStr(ff)+
' was fire.');
end;


end;

Comments

  • gpigpi
    edited 4:25PM
    Use
    Statement:='SELECT * FROM Table_1 where FAUF=' + ff;
    

Leave a Comment