掲示板システム
ホーム
アクセス解析
カテゴリ
ログアウト
TStringGrid の入力について (ID:33362)
名前
ホームページ(ブログ、Twitterなど)のURL (省略可)
本文
こんな感じ? procedure TForm2.StringGrid1KeyDown(Sender: TObject; var Key: Word;Shift: TShiftState); var Row,Col: Integer; begin if goEditing in StringGrid1.Options then begin if Key = 13 then begin StringGrid1.Options := StringGrid1.Options - [goEditing]; for Row := StringGrid1.Selection.Top to StringGrid1.Selection.Bottom do begin for Col := StringGrid1.Selection.Left to StringGrid1.Selection.Right do begin StringGrid1.Cells[Col,Row] := StringGrid1.Cells[StringGrid1.Col,StringGrid1.Row]; end; end; end; end else begin StringGrid1.Options := StringGrid1.Options + [goEditing]; end; end;
←解決時は質問者本人がここをチェックしてください。
戻る
掲示板システム
Copyright 2021 Takeshi Okamoto All Rights Reserved.