var s:string;
i,sCount:integer;
begin
s:='123'
// 字符串
sCount:=5
// char(0)的个数
for i:=0 to sCount-1 do
s:=s+#0
// 加在后面的,如果加在前面的,则:s:=#0+s;
showmessage(inttostr(length(s)));
end;
procedure TForm1.Button1Click(Sender: TObject);
var
s: string;
i: integer;
begin
s := 'abc' + #0 + '123';
for i := 1 to length(s) do
if s = #0 then
s := ' ';
caption := s;