Page 1 of 1

report's saybitmap method

PostPosted: Mon Apr 13, 2009 1:38 pm
by Marcelo Via Giglio
Hello,

this bug has many years, until now I don't know how can I fix this

The saybitmap method don't work with bitmap from resources, this work properly with
bmp files directly.

Maybe some body have the solution?

best regards

Marcelo

Re: report's saybitmap method

PostPosted: Mon Apr 13, 2009 3:59 pm
by Enrico Maria Giordano
It seems to work fine here:

Code: Select all  Expand view
#include "Fivewin.ch"


FUNCTION MAIN()

    LOCAL oPrn

    PRINT oPrn PREVIEW
        PAGE
            oPrn:SayBitmap( 0, 0, "OPEN", 1000, 1000 )
        ENDPAGE
    ENDPRINT

    RETURN NIL


This is the RC file:

Code: Select all  Expand view
OPEN BITMAP "c:\fwh\bitmaps\open.bmp"


EMG

Re: report's saybitmap method

PostPosted: Mon Apr 13, 2009 4:15 pm
by Marcelo Via Giglio
Enrico,

yes from printer class this work ok, but not from the report class, this is strange, because the report class use printer class inside, but from report this not work


reagards

Marcelo

Re: report's saybitmap method

PostPosted: Mon Apr 13, 2009 4:50 pm
by Enrico Maria Giordano
It doesn't work because TReport sets the resource to prev32.dll hiding the currently active resource file.

EMG

Re: report's saybitmap method

PostPosted: Mon Apr 13, 2009 6:17 pm
by Marcelo Via Giglio
Enrico

yuo are right, I move prev32.dll to prev.red and add to my project, and delete all the reference to external resource in rpreview.prg,
then I have a more compact enviroment and I can work with resources in report, thanks for your time

This means that I was wrong and no FW

regards

Marcelo