procedure TForm2.QRDBText1Print(sender: TObject; var Value: String);
var
bExit : boolean;
iLen : integer;
strSource, strTemp : string;
begin
if Length(Value) <= 32 then
exit;
strSource := Value;
Value := '';
while true do
begin
iLen := 1;
while iLen < 32 do
begin
if ord(strSource[iLen]) > 128 then
inc(iLen, 2)
else
inc(iLen);
end;
dec(iLen);
strTemp := Copy(strSource, 1, iLen);
if Value = '' then
Value := strTemp
else
Value := Value + #13 + strTemp;
strSource := Copy(strSource, iLen + 1, Length(strSource) - iLen);
if Length(strSource) <= 32 then
begin
Value := Value + #13 + strSource;
exit;
end;
end;
end;