how to get a random line from a random file

  • Автор темы Автор темы Lannister
  • Дата начала Дата начала

Lannister

Client
Регистрация
28.08.2011
Сообщения
19
Реакции
2
Баллы
0
hi,

how to do that in ZP4 : {-File.GetString-|-{-Directory.RandomFile-|-\Resources\-}-|-random-|-true-}

ZP4 is become so complicated :/

thanks !
 
Here it is :)

P.S. I'm sure that there is much better way to do it, but this works also :)
 

Вложения

  • Спасибо
Реакции: Lannister
Thank you for your help :)

but it does not delete the line in the file.
If i want to do that i need to take the content of the file & delete it, get a random line, and write a new file with the new content.

that's a lot of blocks :/
 
You create a list
In list properties set the text file to sync with.
Then use action Operations with lists - Get line
 
  • Спасибо
Реакции: Lannister
Thanks it works, in the file path of the list i set : {-Directory.RandomFile-|-{-Project.Directory-}\files-} ,(I did not think it would work -_-)
 

Кто просматривает тему: (Всего: 0, Пользователи: 0, Гости: 0)