Abstract
An indolizine heterocycle switches from a nonemissive to an emissive form upon protonation. The co-entrapment of this molecular switch and a photoacid generator in polymer films allows the imprinting of fluorescent patterns in the resulting materials. These operating principles permit the writing and reading of information under optical control.