remove/store the reference to selected object