Recent

Author Topic: problem with LazReport MacOSX  (Read 2869 times)

justanotherjay

  • New Member
  • *
  • Posts: 13
problem with LazReport MacOSX
« on: February 07, 2012, 10:41:44 am »
Hey,

i've a simple procedure which i use to print reports.
Code: [Select]
procedure TDataModuleReport.RepPrint(aRepName:String; aPrewiev:Boolean);
begin
  OpenReport(aRepName);
  with frReportMain do
  begin
    PrepareReport;
    if aPrewiev then
    ShowReport
    else
  PrintPreparedReport(pnPageNrString, 1);
  end;
end;

under windows there is no problem.

under mac i can't call this procedure from an event (action or direct event call).
if i do i get an "RunError(100)" and the compiler jumps to "LCLProc" line 1582
Code: [Select]
Dump_Stack(DebugText^, get_frame);
if i call this procedure from the FormShow event, there is no problem.

Lazarus 0.30.2
FPC 2.4.4

greetings

justanotherjay

  • New Member
  • *
  • Posts: 13
Re: problem with LazReport MacOSX
« Reply #1 on: February 07, 2012, 12:30:32 pm »
well i made a little workaround and now it works.

i created a new procedure inside the frame with my PrintAction.

after PrintAction is fired it calls the new Print procedure. The print procedure calls the RepPrint procedure from the datamodul and it works.

the problem is: i cant call the RepPrint which is inside the datamodule directly from an event / action



 

TinyPortal © 2005-2018