Removes the specified control from the current form's Controls collection.
App.ActiveForm.Controls.Remove(Ctrl)
Newlook Smartclient
Newlook Server
Ctr – (Object, Required)
The control to be removed. It is possible to reference a control by either its name or its index in the controls collection.
Returns a Boolean indicating the success or failure of the action.
The following code will remove an inserted label from the controls collection:
function RemoveWarningByName()
{
//Remove inserted Warning label control using its name
removeSuccess = App.ActiveForm.Controls.Remove(lbWarning);
App.SetValue("RemoveSuccess", removeSuccess);
}
function RemoveWarningByIndex()
{
//Remove inserted Warning label using its index
var warningIndex = App.ActiveForm.Controls.lbWarning.FormControlsCollectionIndex;
removeSuccess = App.ActiveForm.Controls.Remove(App.ActiveForm.Controls(warningIndex));
App.SetValue("RemoveSuccess", removeSuccess);
}
Sub RemoveWarningLabel
'Remove warning label using its name.
App.ActiveForm.Controls.Remove App.ActiveForm.Controls.lbWarning
End Sub
Add Method - Controls | RefreshForm method | Remove Method - Function Keys | Remove Method - Items | Remove Method - Nodes | Remove Method - Columns Headers
ListView ColumnHeaders collection
© 2004-2021 looksoftware. All rights reserved.