$list remove empty

Allows you to remove empty list items from a list.


Example

Running this code will add two blank lists and "1 2 3 4" in the list named "%List1".

"%List2" will include the contents of "%List1" with the empty lines removed.

This alert box is now showing the contents of "%List2".

This is shown in the Debugger.

add item to list(%List1,"","Don\'t Delete","Global")
add list to list(%List1,$list from text("1,2,3,4",","),"Don\'t Delete","Global")
add item to list(%List1,"","Don\'t Delete","Global")
add list to list(%List2,$plugin function("Data and Files Automation.dll", "$list remove empty", %List1),"Delete","Global")
alert(%List2)

Was this helpful?

Previous Article

$list remove at

Next Article

$list remove list