Board index » delphi » SaveToFile - Pdox Graphic to Bitmap File How? \

SaveToFile - Pdox Graphic to Bitmap File How? \

Hi,

I'm working with a Pdox 7 table that has a Graphic field.  I'm trying
to SaveToFile the image to a bitmap file.  Why doesn't this code work?

Table1Boximage.SaveToFile('C:\001videos\'+Table1Title.AsString+'.bmp');

Thanks,

Robert Parlato

Sent via Deja.com http://www.deja.com/
Before you buy.

 

Re:SaveToFile - Pdox Graphic to Bitmap File How? \


Hi... here's how I solved this:

uses JPEG;
.
.
procedure TForm1.Button1Click(Sender: TObject);
var
  bBmp: TBitmap;
  jJpg: TJPEGImage;
begin
  bBmp := TBitmap.Create;
  jJpg := TJPEGImage.Create;
   while not Table1.EOF do
    begin
      bBmp.Assign(Table1Boximage);
      jJpg.Assign(bBmp);
      jJpg.SaveToFile('C:\001\Test\'+Table1Title.AsString+'.jpg');
      Table1.Next;
    end;
  bBmp.Free;
  jJpg.Free;
end;

In article <84qb4e$7p...@nnrp1.deja.com>,

Quote
  rparl...@my-deja.com wrote:
> Hi,

> I'm working with a Pdox 7 table that has a Graphic field.  I'm trying
> to SaveToFile the image to a bitmap file.  Why doesn't this code work?

> Table1Boximage.SaveToFile

('C:\001videos\'+Table1Title.AsString+'.bmp');

Quote

> Thanks,

> Robert Parlato

> Sent via Deja.com http://www.deja.com/
> Before you buy.

Sent via Deja.com http://www.deja.com/
Before you buy.

Other Threads