Cannot Focus a disable or invaiible windows
Posted: 27.09.2005, 07:50
For Example : Form 1 's button method , call dm's query
----------------------------------------------------------------------
[syntax="delphi"] with dmdbConnPool do begin
with Q_EMPLOYEE do begin
JPG.Assign(Image1.Picture.Graphic);
JPG.SaveToStream(MS);
MS.Position:=0;
EDIT;
TBlobField(FieldbyName('PHOTO')).LoadFromStream(MS);
Post; // When I post, Error Message occour
// Cannot Focus a disable or invaiible windows
exit;
end;
end;[/syntax]
----------------------------------------------------------
I have second question, while i use sql to save jpg image to mysql database, always get half of image or less than half image which compare with orginal. However, If I use bitmap, the whole image can save.
Thank you your much for any help.
[edit="Michael"]I put your sourcecode into syntax-tags - looks better now [/edit]
----------------------------------------------------------------------
[syntax="delphi"] with dmdbConnPool do begin
with Q_EMPLOYEE do begin
JPG.Assign(Image1.Picture.Graphic);
JPG.SaveToStream(MS);
MS.Position:=0;
EDIT;
TBlobField(FieldbyName('PHOTO')).LoadFromStream(MS);
Post; // When I post, Error Message occour
// Cannot Focus a disable or invaiible windows
exit;
end;
end;[/syntax]
----------------------------------------------------------
I have second question, while i use sql to save jpg image to mysql database, always get half of image or less than half image which compare with orginal. However, If I use bitmap, the whole image can save.
Thank you your much for any help.
[edit="Michael"]I put your sourcecode into syntax-tags - looks better now [/edit]