Fixed RemoveSelected function