Главная страница
Top.Mail.Ru    Яндекс.Метрика
Текущий архив: 2003.10.16;
Скачать: CL | DM;

Вниз

как разбить строку на лексемы   Найти похожие ветки 

 
Армянское радио   (2003-10-05 07:00) [0]

Сущий привет!

Сущий ара падскажи как разбить строку на лексемы
строка:"123123 23123 fghghfgh"

Сущий ара заранее благадарен!


 
Song ©   (2003-10-05 09:23) [1]

TStringList.CommaText


 
Армянское радио   (2003-10-05 09:33) [2]

А поканкретнее не мог бы :)


 
Palladin ©   (2003-10-05 09:37) [3]

а что конкретней? справку по TStrings.Delimiter почитай...


 
Song ©   (2003-10-05 09:37) [4]

With TStringList.Create Do
try
CommaText:="123123 23123 fghghfgh";
For t:=0 to Count-1 Do ShowMessage(Strings[t]);
finally
Free;
end;


 
Palladin ©   (2003-10-05 09:45) [5]


> Song © (05.10.03 09:37) [4]

CommaText это CommaText и с пробелом не прокатит


 
Palladin ©   (2003-10-05 09:48) [6]

сорри... прокатит....


 
Song ©   (2003-10-05 09:57) [7]

2Palladin © (05.10.03 09:48) [6]

Lists the strings in the TStrings object in system data format (SDF).

property CommaText: string;

Description

Use CommaText to get or set all the strings in the TStrings object in a single comma-delimited string.

When retrieving CommaText, any string in the list that include spaces, commas or quotes will be contained in double quotes, and any double quotes in a string will be repeated. For example, if the list contains the following strings:

Stri,ng 1

Stri"ng 2
String 3
String4

CommaText will return:

"Stri,ng 1","Stri""ng 2","String 3",String4

When assigning CommaText, the value is parsed as SDF formatted text. For SDF format, strings are separated by commas or spaces, and optionally enclosed in double quotes. Double quote marks that are part of the string are repeated to distinguish them from the quotes that surround the string. Spaces and commas that are not contained within double quote marks are delimiters. Two commas next to each other will indicate an empty string, but spaces that appear next to another delimiter are ignored. For example, suppose CommaText is set to:

"Stri,ng 1", "Stri""ng 2" , String 3,String4

The list will then contain:

Stri,ng 1

Stri"ng 2
String
3
String4

Note: CommaText is the same as the DelimitedText property with a delimiter of ‘,’ and a quote character of ‘”’.



Страницы: 1 вся ветка

Текущий архив: 2003.10.16;
Скачать: CL | DM;

Наверх




Память: 0.48 MB
Время: 0.016 c
1-51329
COSINUS
2003-10-02 20:00
2003.10.16
Параллельная прокрутка


1-51300
malefik
2003-10-06 10:09
2003.10.16
Строки замучили.... как преобразовать?????


1-51303
den74
2003-10-06 13:12
2003.10.16
Перерисовка формы


14-51417
handra
2003-09-26 13:09
2003.10.16
ИК-пульт


7-51539
mihmax
2003-07-31 15:29
2003.10.16
Администрирование Windows2000