$list random

Allows you to return a random list item from a specified list.


Example

Running this code will add the following texts to the list named "%people_list".

  • karen
  • roger
  • peter
  • john
  • kevin
  • sally
  • chet
  • niki
  • lee
  • jackie
  • benny
  • fiona
  • kenny

After running this code, the list "%people_list" will be randomized when the HTML loads.

This is shown in the alert box.

add list to list(%people_list,$list from text("karen
roger
peter
john
kevin
sally
chet
niki
lee
jackie
benny
fiona
kenny",$new line),"Delete","Global")
load html($plugin function("Data and Files Automation.dll", "$nl to br", $plugin function("Data and Files Automation.dll", "$list random", %people_list, 0, "Total", "False", "False")))

Was this helpful?

Previous Article

$list merge

Next Article

$list remove