02-06-2017, Saat: 12:07
Uygulamada global olan bir formdaki Edit, CheckBox, ComboBox, değerlerini kopyalayıp, yapıştırmak için bir kodcuk yazmıştım buraya da ekleyeyim 

uses ClipBrd;
procedure ClipBoardCopy;
var
i: integer;
t: TStringList;
begin
t := TStringList.Create;
try
for i := 0 to ComponentCount - 1 do
begin
if (Components[i] is TEdit) then
begin
t.Add((Components[i] as TEdit).Name + '=' +
(Components[i] as TEdit).Text)
end;
if (Components[i] is TComboBox) then
begin
t.Add((Components[i] as TCheckBox).Name + '=' +
Booltostr((Components[i] as TCheckBox).Checked))
end;
if (Components[i] is TComboBox) then
begin
t.Add((Components[i] as TComboBox).Name + '=' +
inttostr((Components[i] as TComboBox).ItemIndex))
end;
end;
finally
Clipboard.AsText := t.Text;
t.Free;
end;
end;
procedure ClipBoardPaste;
var
i,a: integer;
t: TStringList;
begin
t := TStringList.Create;
try
t.Text := Clipboard.AsText;
for a := 0 to t.Count - 1 do
begin
for i := 0 to ComponentCount - 1 do
begin
if (Components[i] is TEdit) then
begin
if ((Components[i] as TEdit).Name = Copy(t[a],0,Pos('=',t[a])-1) ) then
(Components[i] as TEdit).Text := Copy(t[a],Pos('=',t[a])+1,Length(t[a]));
end;
if (Components[i] is TCheckBox) then
begin
if ((Components[i] as TCheckBox).Name = Copy(t[a],0,Pos('=',t[a])-1) ) then
(Components[i] as TCheckBox).Checked := StrToBool(Copy(t[a],Pos('=',t[a])+1,Length(t[a])));
end;
if (Components[i] is TComboBox) then
begin
if ((Components[i] as TComboBox).Name = Copy(t[a],0,Pos('=',t[a])-1) ) then
(Components[i] as TComboBox).ItemIndex := StrToInt(Copy(t[a],Pos('=',t[a])+1,Length(t[a])));
end;
end;
end;
finally
t.Free;
end;
end;


