I have a text of tab-delimited items. In some of those items, there are alternate sub-items (separated by slash). I want to get a text where only one sub-item per tab-delimited item is selected.
Sample:
Code: Select all
put "326 I'm OK Je vais bien Aussi Merci Savoir Grand It is/Il est/Elle est Savoir/Connaître" into tWordList
set the itemdel to tab
put 0 into tItemNumber
repeat for each item tItem in tWordList
add 1 to tItemNumber
if tItem contains "/" then
set the itemdel to "/"
put any item of tItem into tSelected
put tSelected into item tItemNumber of tWordList
set the itemdel to tab
end if
end repeat