/mailman/listinfo/fpc-pascal
--
Andrea Mauri
PhD student - Chemical Sciences
Milano Chemometrics and QSAR Research Group
Department of Environmental Sciences
University of Milano-Bicocca
P.zza della Scienza, 1
20126 Milano - Italy
Tel: ++39 02 64482801
mailto:[EMAIL PROTECTED]
http
I used this, check it.
// Returns an array with the parts of str separated by separator
function Split(const str: string; const separator: string): array of string;
var
i, n: integer;
strline, strfield: string;
begin
n:= Occurs(str, separator);
SetLength(Result, n + 1);
i := 0;
strline:=
occurs is:
function Occurs(const str, separator: string): integer;
var
i, nSep: integer;
begin
nSep:= 0;
for i:= 1 to Length(str) do
if str[i] = separator then Inc(nSep);
Result:= nSep;
end;
Andrea Mauri ha scritto:
I used this, check it.
// Returns an array with the parts of str