Thanks! Em 07/02/2012, às 12:32, Felipe Monteiro de Carvalho escreveu:
> Each class can only read 1 format. > > btnAdd.Glyph is a TBitmap and therefore reads only bitmaps. But you > can first read to a PNG and then use Assign to convert to a bitmap. > > Try doing it like this: > > var > MyPNG: TPortableNetworkGraphic; > begin > MyPNG := TPortableNetworkGraphic; > MyPNG.LoadFromLazarusResource('edit_add'); > btnAdd.Glyph.Assign(MyPNG); > MyPNG.Free; > > -- > Felipe Monteiro de Carvalho > > -- > _______________________________________________ > Lazarus mailing list > Lazarus@lists.lazarus.freepascal.org > http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus -- _______________________________________________ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus