Control of the orientation and photoinduced phase transitions of macrocyclic azobenzene.