setActive method