T
tsucol
Unregistered / Unconfirmed
GUEST, unregistred user!
TDrawGrid的Canvas属性能否保存为图象,比如,我用
DrawGrid1.Canvas.MoveTo(0,0);
DrawGrid1.Canvas.LineTo(Drawgrid2.Width,Drawgrid2.Height);
画了条直线,现在想将DrawGrid1保存为bmp图象,请问如何实现?
我用
bmp := TBitmap.Create;
bmp.Canvas.CopyRect(DrawGrid2.ClientRect,DrawGrid2.Canvas,DrawGrid2.ClientRect);
try
with bmp do
begin
SaveToFile('c:/111.bmp');
end;
finally
bmp.Free;
end;
好象不能实现。
DrawGrid1.Canvas.MoveTo(0,0);
DrawGrid1.Canvas.LineTo(Drawgrid2.Width,Drawgrid2.Height);
画了条直线,现在想将DrawGrid1保存为bmp图象,请问如何实现?
我用
bmp := TBitmap.Create;
bmp.Canvas.CopyRect(DrawGrid2.ClientRect,DrawGrid2.Canvas,DrawGrid2.ClientRect);
try
with bmp do
begin
SaveToFile('c:/111.bmp');
end;
finally
bmp.Free;
end;
好象不能实现。