Coordination-driven self-assembly directs a single-crystal-to-single-crystal transformation that exhibits photocontrolled fluorescence.