Jump to content
Fivewin Brasil

Converter de String para BMP


Jmsilva

Recommended Posts

include "FiveWin.ch"

function Main()

local hBmp := ReadBitmap( 0, "test.bmp" )

MsgInfo( hBmp )

MemoWrit( "another.bmp", BmpToStr( hBmp ) )

DeleteObject( hBmp )

return nil

Para Converter um BMP para String usa-se BmpToStr() e o Inverso, Alguém sabe?

Fivewin 9.11

Caraguatatuba-SP

Editado por - Jmsilva on 13/12/2009 12:31:55

Link to comment
Share on other sites

include "FiveWin.ch"

function Main()

local hBmp := ReadBitmap( 0, "test.bmp" )

MsgInfo( hBmp )

MemoWrit( "another.bmp", BmpToStr( hBmp ) )

DeleteObject( hBmp )

return nil

Para Converter um BMP para String usa-se BmpToStr() e o Inverso, Alguém sabe?

Fivewin 9.11

Caraguatatuba-SP

Editado por - Jmsilva on 13/12/2009 12:31:55

Link to comment
Share on other sites

Um exemplo:

#include "Fivewin.ch"

function main

local oDlg, oBmp, hBmp, cBmp

local hBmp := ReadBitmap( 0, "test.bmp" ) // cria o handle da imagem

local cBmp := BmpToStr( hBmp ) // gera a string do bmp

define dialog odlg RESOURCE "TELA"

redefine bitmap obmp id 4001 of odlg

obmp:LoadFromString( cBmp ) // carrega a string

activate dialog odlg

DeleteObject( hBmp )

return nil

http://www.redstarsoft.com.br

xHarbour 1.2.1 | Fivewin 9.10 | MySQL

Link to comment
Share on other sites

  • 1 month later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...