TEdit and etc. components

edited 3:04AM in FastReport 3.0
Please help,

how to use transfer text from normal TEdit component on application Form1 into Memo1 in Report form ?

this is not work:
frxReport1->Memo1->Add (Form1->Edit1->Text);

thank you for help.
stan

Comments

  • theodoretheodore Greece
    edited 3:04AM
    Hello...
    You have to pass a variable:
    1.Form->frxReport->Variables->Variables[" variablesfromprogram"]=NULL; // to add a kategory named variablesfromprogram (notice the starting space)

    2a)Form->frxReport->Variables->Variables["passedvariable"]=Form1->Edit1->Text // to add a variable named passedvariable with value 'text' - notice you add the variable to the last kategory which is variablesfromprogram - as from 1.
    2b)Form->frxReport->Variables->AddVariable("variablesfromprogram","passedvariable",Form1->Edit1->Text) // another way to pass a variable where you select an existing kategory, variable name and then pass the value

    3) After you have passed a variable and a value you can assign the variable to the memo: double click the memo -> click Fx-> Click variables tab->Double click the variable -> press OK

    Hope it helps....
    Theo
  • edited 3:04AM
    ad 3)
    Variable in Variables Tab is not there.

    Form1->frxReport1->Variables->Variables["Editor"]=NULL;
    Form1->frxReport1->Variables->AddVariable("Editor","text",Form1->Edit1->Text) ;


    whats problem?

    thank you for help.

    stan
  • theodoretheodore Greece
    edited 3:04AM
    Hi
    try
    Form1->frxReport1->Variables->Variables[" Editor"]=NULL;
    //notice the starting space - as before. To add a kategory you must start the kategory name with a space!!! A kategory is needed to add the variable in. If you do not have a kategory you cannot pass the values. You 'll find the variable under variables->kategory Editor

Leave a Comment