Hi

Thanks! its working. Now please help me to get an Image from a blob
field in Mysql 4.1 database.

I am working for a school. What we need is a checking system to show the
photos of the Student , parents and guardians after keying in the Roll No.

This would be my very first real work on lazarus. I will be showing it
on a Linux thin client, on a 486. Next stage is to rewrite all my Delphi
4 code to lazarus , without MyOdbc and BDE load.

Another unorthodox way is to store all the images in the file system,
giving the name same as the roll numbers, and then loading each file
into the TImage as and when a roll no is keyed in.

I tried something like this :- But giving SIG errors

Stream:=TMemoryStream.create;
Stream:=sqlquery1.CreateBlobStream(sqlquery1.FieldByName('pdf') as
TBlobField,bmRead);
// Stream.Position:=0;
Image1.Picture.Bitmap.LoadFromStream(stream);
Stream.free;


Plz help

regards

Nataraj

Mattias Gaertner wrote:

On Fri, 22 Sep 2006 16:35:10 +0530
Nataraj S Narayan <[EMAIL PROTECTED]> wrote:

Hi

Something happened.

Just now updated svn, after which RegisterImg4Laz is missing and ImageForLazarus dont compile.

Sorry. I forgot to commit one file. Fixed.

[EMAIL PROTECTED]:~# svn update lazarus
At revision 9963.

The previous revision compiles but not able to view jpeg.

Because you had to call the register procedure yourself.

Mattias



regards

Nataraj

Mattias Gaertner wrote:

On Fri, 22 Sep 2006 15:39:45 +0530
Nataraj S Narayan <[EMAIL PROTECTED]> wrote:



Hi

No, i havent added to Projects Inspector. Should I remove
JpegForLazarus now , since I have ImageForLazarus?
Yes.
Don't forget to update lazarus.



Further, will TDbImage work with SqlDB to retreive the images from
MySql blob field?
I never tried - probably.

Mattias




regards

Nataraj





Mattias Gaertner wrote:

On Fri, 22 Sep 2006 14:17:53 +0530
Nataraj S Narayan <[EMAIL PROTECTED]> wrote:



Hi

I am able to view a .xpm file in a TImage component. But not able
to view a jpg file.

The Components->Open Loaded Packages , ImageForLazarus and JpegForLazarus are listed.

Could it be any conflict b/w these?
No. But if you use imagesforlazarus you don't need jpegforlazarus.




I prefer to use .jpg  as the file size of a .xpm is manyfold than
a .jpg.

Plz help
Did you add jpegforlazarus to your project dependencies (Project
Inspector)?

The ImagesForLazarus registered its image formats only at design
time. I changed it to register them at runtime too.


Mattias










begin:vcard
fn:http://www.gsis.ac.in
n:S Narayan;Nataraj
org:Good Shepherd International School;Software
adr:Niligiris, ;;M.Palada;Ootacamund;TN;643004;INDIA
email;internet:[EMAIL PROTECTED]
title:Project Coordinator
tel;work:0423 2550371 - 307
x-mozilla-html:TRUE
url:http://www.gsis.ac.in
version:2.1
end:vcard

Reply via email to