xe

var
  s: string;
  sList: TStringList;
begin
  s := 'aaa,bbb,cc c,dd dd,eee';
  sList := TStringList.Create;
  sList.StrictDelimiter := True;  //Delph7无此属性
  sList.Delimiter := ',';
  sList.DelimitedText := s;
  ShowMessage(sList.Text);     
  sList.Free;
end;


分离包含空格字符串[xe & D7]_Text



D7

uses
  IdStrings;

procedure TForm1.Button1Click(Sender: TObject);
var
  s: string;
  sList: TStringList;
begin
  s := 'aaa,bbb,cc c,dd dd,eee';
  sList := TStringList.Create;
  SplitColumns(s, sList, ','); //uses idStrings
  ShowMessage(sList.Text);
  sList.Free;
end;