User's Functions and Parameters

Hi. I've added some functions to FastReport by means of the definition of the class TfrMyFunctions = class (TfrFunctionLibrary). I've specified the methods "create" and "dofunction". It runs well.
In the master detail's event "OnBeforePrint" I've put the next code:
begin
     Aux1:=[ModuloInformes.ARTICULOS."NCOD_EJERCICIO"];
     Aux2:=[PAGE#];
     if GenIDX='S' then GRABAR([Aux1],[Aux2]);
end;
where Aux1, Aux2 and GenIDX are variables defined in the FR Dictionary. The problem is DoFunction receives parameters p1,p2 but its values are p1='[Aux1]' and p2='[Aux2]' instead of p1='<value of field>' and p2=<page number>.
Why doesn't it pass the value? How Can I do it?
Thanks.

Comments

Leave a Comment

Rich Text Editor. To edit a paragraph's style, hit tab to get to the paragraph menu. From there you will be able to pick one style. Nothing defaults to paragraph. An inline formatting menu will show up when you select text. Hit tab to get into that menu. Some elements, such as rich link embeds, images, loading indicators, and error messages may get inserted into the editor. You may navigate to these using the arrow keys inside of the editor and delete them with the delete or backspace key.