Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Intraweb session variables
(04-24-2019, 07:43 PM)Jose Nilton Pace Wrote: Hi, if you don't prepare report, prepare it before export.
frxReport.Export( frxPDFExport );

this my code
         QRpt := TfrxReport.Create(Nil);
        QRpt.EngineOptions.DestroyForms := False;
        QRpt.EngineOptions.SilentMode := True;
        QRpt.EngineOptions.EnableThreadSafe := True;

         (* assigning all frx datasets here *)
         (* opening all frx datasets *)

      if QRpt.PrepareReport(True) then
            QoExportfilter := TfrxCustomExportFilter(frxPDFExport1);
            QoExportfilter.FileName := QteUrl;
            raise Exception.Create('Reporting error');


(04-24-2019, 07:58 PM)zsleo Wrote:
(04-24-2019, 07:22 PM)msgopala Wrote: Had some report crossover as far as fastreport and cache issues are concerned read a post that to keep local variables to a minimum as they are common to all threads so moved over reporting variables to UserSession datamodule. 

What is happening is if a user is printing a report, sometimes its right. Sometimes the report has data which was previously printed by a completely different client. The reports are exported using frxPDFExport component and saved on the server  where my dll is hosted from. 

Of course this didn't happen in the standalone and while we tested because we didnt have multiple external users accessing the application. The reports are first generated and exported and then sent via Webapplication.sendfile(path + filename). Filename changes everytime.

What I have tried :,, moving variables to USersessionDM. Still continues to happen. 

Report for John Doe prints correctly, Next while printing Jane Doe the report name says Jane Doe but data inside is of John Doe. How do I rectify this. My rpRpt.fr3 is stored on the server as well and how do I get it to to be specific to each session. 

The print report proc is not in the UserSessionDM but on the main form.

Thanks for all your help.

This is a common FR threading issue.  For potential  solutions see
ok Thanks

Messages In This Thread
Intraweb session variables - by msgopala - 04-24-2019, 07:22 PM
RE: Intraweb session variables - by msgopala - 04-25-2019, 12:59 PM
RE: Intraweb session variables - by zsleo - 04-24-2019, 07:58 PM

Forum Jump:

Users browsing this thread: 2 Guest(s)