Remove Method - ListView Column Header

This method removes the specified column, header and items from the control.

Client support

   Newlook Smartclient only.

Syntax

App.ActiveForm.ListViewControl.ColumnHeaders.Remove(Index)

Parameters

Index – (Integer, Required)

The index of the list item or column to be removed.

Returns

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

Use

It is worth noting that the View property of a ListView control must be set to Report, in order to view column headers in the control.

Examples

The following example will remove the entire 1st column from a ListView control:

JSCRIPT

function RemoveColumn()

{

//Remove the first column

removeSuccess = App.ActiveForm.ListViewControl.ColumnHeaders.Remove(0);

App.SetValue("RemoveSuccess", removeSuccess);

}

 

VB SCRIPT

Sub RemoveColumn

   'Remove 1st column of list view and its data

   App.ActiveForm.ListViewControl.ColumnHeaders.Remove (0)

End Sub

See Also

Add Method - ColumnHeaders | Add Method - Items | Clear Method | RefreshForm method | Remove Method - Function Keys | Remove Method - Items | Remove Method - Nodes | Remove Method - Controls

Applies To

ListView ColumnHeaders collection


© 2004-2021 looksoftware. All rights reserved.