unit Unit1; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls; type TForm1 = class(TForm) Button1: TButton; Button2: TButton; procedure Button1Click(Sender: TObject); procedure Button2Click(Sender: TObject); private { Private declarations } public { Public declarations } end; var Form1: TForm1; implementation {$R *.dfm} uses Types, testDelimitedTextUnit; procedure MessageArray(Values: array of String); var i: Integer; begin for i := 0 to Length(Values) -1 do begin ShowMessage((Values[i])); end; {-------------------------------------- 0〜Length(Values)-1 以外に 0〜High(Values) という指定方法でもよい --------------------------------------} end; procedure TForm1.Button1Click(Sender: TObject); var Args: TStringDynArray; begin MessageArray([]); MessageArray(['あいうえお', 'かきくけこ', 'さしすせそ']); SetLength(Args, 3); Args[0] := 'ABCD'; Args[1] := 'EFGH'; Args[2] := 'IJKL'; MessageArray(Args); end; procedure TForm1.Button2Click(Sender: TObject); begin testWordGet; testWordCount; testSplit; end; end.