Clear Method - ListBox

This method clears the contents of the list array.

ListViw object.Clear()

Client support

   Newlook Smartclient

   Newlook Server

Parameters

None.

Returns

Returns a Boolean indicating the success or failure of the action.

Examples

The following example removes all host generated items from the ListBox list and adds two custom items.

JSCRIPT

function UpdateList()

{

//Clear current items from the ListBox

App.ActiveForm.Controls.ListControl.Clear();

 

//Add new items to list

App.ActiveForm.Controls.ListControl.Additem("WRKACTJOB",0);

App.ActiveForm.Controls.ListControl.Additem("WRKSPFL",1);

 

//Refresh list

App.RefreshForm();

}

See Also

List property | AddItem Method | RemoveItem Method

Applies To

ListBox control


© 2004-2021 looksoftware. All rights reserved.