FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour print a bitmap (from resources)
Posts: 7317
Joined: Thu Oct 18, 2012 07:17 PM
print a bitmap (from resources)
Posted: Sun Jan 29, 2017 11:48 AM

I need to show a bitmap from resource on treport

Local aBmpBusca:={"RIBBON_COLLEZIONI",;
"RIBBON_COLLEZIONI",;
"RIBBON_PELLICOLA"}

ACTIVATE REPORT oInforme:oReport
....
ON STARTPAGE StartPage(oInforme,aBmpBusca[nkey])


STATIC Function StartPage(oInforme,cLogoBmp)
oInforme:oReport:SayBitmap(.3,.25,cLogoBmp,50,50)
RETURN NIL

why not print the bitmap ?

Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)

I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: print a bitmap (from resources)
Posted: Sun Jan 29, 2017 02:40 PM
oReport:SayBitmap in turn calls oReport:SayImage() and this method does not support resources. Even if you are using bmpfile, you better specify the scale RPT_INCHES or RPT_CMETERS as 5th parameter.

Instead I advise to try this:

Code (fw): Select all Collapse
STATIC Function StartPage(oInforme,cLogoBmp)

   @ 1, 1 PRINT TO oInforme:oReport:oDevice IMAGE cLogoBmp ;
      SIZE 5, 5 CM   // CM or MM or INCHES or PIXELS

RETURN NIL
Regards



G. N. Rao.

Hyderabad, India
Posts: 7317
Joined: Thu Oct 18, 2012 07:17 PM
Re: print a bitmap (from resources)
Posted: Sun Jan 29, 2017 03:25 PM

PRINT ??
I not Known this command ...THANKS RAO!!!
ok now run ..

Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)

I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: print a bitmap (from resources)
Posted: Mon Jan 30, 2017 01:59 AM
Silvio.Falconi wrote:PRINT ??
I not Known this command ...THANKS RAO!!!
ok now run ..

I advise you to keep reading whatsnew.txt
Regards



G. N. Rao.

Hyderabad, India

Continue the discussion