gui.removeAllListItems

Removes all items from a list.

Prototype

  1. bOk = gui.removeAllListItems ( hComponent )

Parameters

hComponent - valid GUI component handle


Return values

bOk - true if successful


Sample

  1. function onMainViewRefreshAdditionalFilesList ( hList, sAdditionalFiles )
  2.  
  3. if ( hList ) then
  4. local tFiles = string.explode ( sAdditionalFiles, ";" )
  5. if ( tFiles ) then
  6. gui.removeAllListItems ( hList )
  7.  
  8. for i = 1, #tFiles do
  9. -- do stuff

Available since ShiVa 2.0