Экспорт в Excel (xml)
Экспорт в Excel (XML)
function TfrxXMLExport.ChangeReturns(const Str: String): String;
var
i: Integer;
begin
Result := '';
for i := 1 to Length(Str) do
begin
if Str = '&' then
Result := Result + '&'
else if (i < Length(Str)) and (Str = #13) and (Str[i + 1] = #10) then
Result := Result + '
' {!!!! было'
'пропущена ';'}
else if Str = '"' then
Result := Result + '"'
else if Str = '<' then
Result := Result + '<'
else if Str = '>' then
Result := Result + '>'
else if (Str <> #10) then
Result := Result + Str
end;
end;
function TfrxXMLExport.ChangeReturns(const Str: String): String;
var
i: Integer;
begin
Result := '';
for i := 1 to Length(Str) do
begin
if Str = '&' then
Result := Result + '&'
else if (i < Length(Str)) and (Str = #13) and (Str[i + 1] = #10) then
Result := Result + '
' {!!!! было'
'пропущена ';'}
else if Str = '"' then
Result := Result + '"'
else if Str = '<' then
Result := Result + '<'
else if Str = '>' then
Result := Result + '>'
else if (Str <> #10) then
Result := Result + Str
end;
end;
Комментарии
function TfrxXMLExport.ChangeReturns(const Str: String): String;
var
i: Integer;
begin
Result := '';
for i := 1 to Length(Str) do
begin
if Str = '&' then
Result := Result + '&'
else if (i < Length(Str)) and (Str = #13) and (Str[i + 1] = #10) then
Result := Result + '
' // было'
' пропущена ';'
else if Str = '"' then
Result := Result + '"'
else if Str = '<' then
Result := Result + '<'
else if Str = '>' then
Result := Result + '>'
else if (Str <> #10) then
Result := Result + Str
end;
end;
else if (i < Length(Str)) and (Str = #13) and (Str[i + 1] = #10) then
Result := Result + '
'+';'
'}