c'e' un end select che pare non abbia apertura