LPARAMETER tlSelected * Parameter is the Boolean value to * assign to all items LOCAL lni ThisForm.LockScreen = .T. FOR lni = 1 TO This.ListCount This.Selected(lni) = tlSelected NEXT ThisForm.LockScreen = .F.This will select or unselect all depending on the value of the parameter passed.