[phpBB Debug] PHP Warning: in file [ROOT]/phpbb/session.php on line 583: sizeof(): Parameter must be an array or an object that implements Countable
[phpBB Debug] PHP Warning: in file [ROOT]/phpbb/session.php on line 639: sizeof(): Parameter must be an array or an object that implements Countable
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4516: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3262)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4516: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3262)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4516: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3262)
Quartam Software Forums •Preview Error
Page 1 of 1

Preview Error

Posted: Tue Jul 26, 2011 8:51 am
by JosepM
Hi Jan,

I have a problem that I don't know how solve. If you can help me...

I try to preview many reports from a repeat loop but ever after the first all the other previews show like the attached snapshot.

Any idea, sometimes I can see how the scrollbars first appear with the correct size but then reduce to appear as I show.

Salut,
Josep M

Re: Preview Error

Posted: Wed Jul 27, 2011 7:25 pm
by JanSchenkel
Hi Josep,

This is a very strange issue - one that I can't seem to simulate on my iMac running MacOSX 10.4 Tiger.
I can try it again on my MacBook Pro running MacOSX 10.6 SNow Leopard later this evening.

Here's what I did:
- I opened LiveCode 4.6.3, then the qrtReportsLib.rev stack, and then the Report samples.rev stack.
- I went to the page for the Simpe Reports - Printing Stacks example, and modified the card script.
- The change was simple, as I simply put a 'repeat 30 times' loop around the call to qrtReports_PrintReportForStack.
- It took some time, but it opened up all the preview windows correctly with everything properly expanded.

If you do the same thing, does it also go haywire in your development environment?

Jan Schenkel.

Re: Preview Error

Posted: Wed Jul 27, 2011 8:28 pm
by JosepM
Hi Jan,

Let me try later and post the results.

My loop code is:

Code: Select all

 ## Load Datagrid data
   ##
   put the long ID of this stack into tStackName
   put the dgData of group "dg_lineas" into sDgData
   put the dgData of group "dg_lineas" into sDgDataCopia
   
   set itemdel to comma
   put item 2 of the extents of sDgData into sRowCount
   
   
   ## Loop to print each record with her image if is available
   ##
   ## First check the number of rows, then for each one call the report.
   ## Also check that the image for the row code exist, if not warn the user asking if want print without image.
   
   
   repeat with x=1 to sRowCount
      put 0 into sRowIndex
      
      MyPrintReport tPlantillaSeleccionada,True
      
   end repeat


   ## End Loop
Salut,
Josep M

Re: Preview Error

Posted: Wed Jul 27, 2011 8:42 pm
by JanSchenkel
No glaring mistakes there, so we'll have to see what happens in a ontrolled enviuronment, and then widen the net until we capture the cause.
In the meantime, I did the same test on my MacBook Pro, and all looked as it should.

Thanks in advance for the feedback,

Jan Schenkel.

Re: Preview Error

Posted: Wed Jul 27, 2011 10:07 pm
by JosepM
One tip, if I resize the erroneous preview, the scrollers are resized to the correct size like the first report, all is moved to their positions, the top buttons... all...

Salut,
Josep M

Re: Preview Error

Posted: Thu Jul 28, 2011 5:36 am
by JanSchenkel
Is it possible that somewhere along the way the 'lockMessages' is set to 'true'? That would prevent the engine from sending a 'resizeStack' event message to the preview stack as it is moved and resized for optimal view by the user. You could try changing your loop to:

Code: Select all

   repeat with x=1 to sRowCount
      put 0 into sRowIndex
      MyPrintReport tPlantillaSeleccionada,True
      if the lockMessages is true then
         put the milliseconds && "messages were locked after run" && x && "- unlocking" & return after msg
         set the lockMessages to false
      end if
   end repeat
And see if that helps and if anything shows up in the message box.

Other question: did you recently add a plug-in to your LiveCode environment? Perhaps a frontscript is grabbing the 'resizeStack' message and not passing it?

Jan Schenkel.