To Antonio:

To Antonio:

Postby HunterEC » Fri Dec 07, 2012 5:32 pm

Antonio:

I'm getting the following report before the report engine displays the report:
Error(6) deleting enhanced metafile

Error description

It is a small dialog with the Ok button and nothing else.

The preview window does not goes away and it stand stills at the report's last page (showing page number 77 and the printer icon).
When I press the preview button, it goes away and after pressing the Ok button (on the error dialog) the reports is displayed.

What I'm trying to do is print a counter on the same line as the grand totals. Thank you.

Windows XP Pro SP3 x86, 8GB RAM (3.25GB usable), Intel Core 2 Quad 3.00GHz, C: partition SSD 38GB free
Code: Select all  Expand view

         ACTIVATE REPORT oRep ;
            ON CHANGE {|| IIF(EVAL(bForCond) .AND. Fecha_ingr <= dDueDate, ;
                              ListStocks(@aVars), NIL)}                    ;
            ON END {|| DispCnt1 (@aVars)}

STATIC PROCEDURE DispCnt1 (aParms)
   #define oReport   aParms[10]
   #define nCtr      aParms[19]

   LOCAL nI

   FOR nI := 1 TO 2
      oReport:StartLine()
      oReport:EndLine()
   NEXT
   oReport:StartLine()
   oReport:Say( 1, "Total: " + LTRIM(STR(nCtr,7)), , 1 )
   oReport:EndLine()

   #undef oReport
   #undef nCtr
RETURN
 
HunterEC
 
Posts: 723
Joined: Tue Sep 04, 2007 8:45 am

Re: To Antonio:

Postby Otto » Fri Sep 13, 2013 8:44 am

Hunter, did you find a solution for your problem?
Best regards,
Otto
********************************************************************
mod harbour - Vamos a la conquista de la Web
modharbour.org
https://www.facebook.com/groups/modharbour.club
********************************************************************
User avatar
Otto
 
Posts: 6332
Joined: Fri Oct 07, 2005 7:07 pm

Re: To Antonio:

Postby Antonio Linares » Fri Sep 13, 2013 9:06 am

Otto,

is it using the printer preview or using the reports engine and the preview ?

Usually you get this because there is an unbalanced Page endPage
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42094
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: To Antonio:

Postby Armando » Fri Sep 13, 2013 2:47 pm

HunterEC:

Please try the next function

Code: Select all  Expand view

STATIC PROCEDURE DispCnt1 (aParms)
   #define oReport   aParms[10]
   #define nCtr      aParms[19]

   LOCAL nI

   FOR nI := 1 TO 2
      oReport:StartLine()
      oReport:EndLine()
      OverFlow(oReport)               // Add this line
   NEXT
   oReport:StartLine()
   oReport:Say( 1, "Total: " + LTRIM(STR(nCtr,7)), , 1 )
   oReport:EndLine()
   OverFlow(oReport)                   // Add this line

   #undef oReport
   #undef nCtr
RETURN


STATIC FUNCTION OverFlow(oReport)
    IF (oReport:nRow + (oReport:nStdLineHeight * 2)) >= oReport:nBottomRow
        oReport:EndPage()
        oReport:StartPage()
    ENDIF
RETURN NIL
 


I hope these can help you

Regards
SOI, s.a. de c.v.
estbucarm@gmail.com
http://www.soisa.mex.tl/
http://sqlcmd.blogspot.com/
Tel. (722) 174 44 45
Carpe diem quam minimum credula postero
User avatar
Armando
 
Posts: 3224
Joined: Fri Oct 07, 2005 8:20 pm
Location: Toluca, México


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 93 guests