Code:
unit Unit1;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, jpeg, ExtDlgs, StdCtrls, ExtCtrls;
type
TForm1 = class(TForm)
Image1: TImage;
Image2: TImage;
Image3: TImage;
Image4: TImage;
Image5: TImage;
Image6: TImage;
Image7: TImage;
Button1: TButton;
OpnPic1: TOpenPictureDialog;
procedure Image6Click(Sender: TObject);
procedure Button1Click(Sender: TObject);
procedure Image5Click(Sender: TObject);
procedure Image4Click(Sender: TObject);
procedure Image3Click(Sender: TObject);
procedure Image2Click(Sender: TObject);
procedure Image1Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
implementation
{$R *.dfm}
procedure TForm1.Image1Click(Sender: TObject);
begin
if opnpic1.execute then
image1.Picture.LoadFromFile(opnpic1.FileName);
end;
procedure TForm1.Image2Click(Sender: TObject);
begin
if opnpic1.execute then
image2.Picture.LoadFromFile(opnpic1.FileName);
end;
procedure TForm1.Image3Click(Sender: TObject);
begin
if opnpic1.execute then
image3.Picture.LoadFromFile(opnpic1.FileName);
end;
procedure TForm1.Image4Click(Sender: TObject);
begin
if opnpic1.execute then
image4.Picture.LoadFromFile(opnpic1.FileName);
end;
procedure TForm1.Image5Click(Sender: TObject);
begin
if opnpic1.execute then
image5.Picture.LoadFromFile(opnpic1.FileName);
end;
procedure TForm1.Image6Click(Sender: TObject);
begin
if opnpic1.execute then
image6.Picture.LoadFromFile(opnpic1.FileName);
end;
procedure TForm1.Button1Click(Sender: TObject);
begin
image7.Canvas.CopyRect(rect(0,0,64,32),image1.Canvas,rect(0,0,64,32));
image7.Canvas.CopyRect(rect(64,0,128,32),image2.Canvas,rect(0,0,64,32));
image7.Canvas.CopyRect(rect(128,0,192,32),image3.Canvas,rect(0,0,64,32));
image7.Canvas.CopyRect(rect(192,0,256,32),image4.Canvas,rect(0,0,64,32));
image7.Canvas.CopyRect(rect(256,0,320,32),image5.Canvas,rect(0,0,64,32));
image7.Canvas.CopyRect(rect(320,0,384,32),image6.Canvas,rect(0,0,64,32));
end;
end.
Bookmarks