CommaExts := CommaExts + ','; S := 1; I := 1; while I <= Length(CommaExts) do begin if CommaExts[I] = ',' then begin WMPRegMultimediaExts(Copy(CommaExts, S, I - S), PerceivedType, MIMEType, ExtDesc); S := I + 1; end; I := I + 1; end;