print a BMP with a string in line

Post Reply
User avatar
dbSoft
Posts: 16
Joined: Thu Oct 13, 2005 8:31 pm
Location: Greece
Contact:

print a BMP with a string in line

Post by dbSoft »

Hi in all
I would want your help
I have in a field of BDF File a string with address from a BMP picture
I want to print a situation in which
The place of picture c:\bmp\test 01. bmp and the picture
How does become this?

I thank,
With price Yannis
User avatar
Patrick Mast
Posts: 244
Joined: Sat Mar 03, 2007 8:42 pm

Re: print a BMP with a string in line

Post by Patrick Mast »

Hello,

Try this:

Code: Select all

#include "FiveWin.ch"

PROCEDURE Main()

   LOCAL cFile:="C:\Bitmaps\agua2.bmp"
   LOCAL oBMP,oPrn
   
   IF MsgYesNo("Print " + cFile + "?")
   
      DEFINE BITMAP oBmp FILE (cFile)
      
      PRINT oPrn
        PAGE
          oPrn:SayBitmap( 1, 1, cFile )
        ENDPAGE
      ENDPRINT
      
      MsgInfo(cFile + " sent to printer.")
      
   ENDIF   

RETURN 
You can assign cFile also from your database like cFile:=field->BITMAP

Patrick
Post Reply