Added capability to programmatically remove selected items.