A stimulated photon echo has been observed from the artificially modulated inhomogeneous distribution of a medium. A cryogenic Eu (3+):YAlO(3) sample with a quasi-persistent hole lifetime is exposed to a frequency-scanned and intensity-modulated cw laser for multiple hole burning. A coherent burst equivalent to the stimulated photon echo is obtained by triggering this sample by a pulsed laser. We demonstrate further that any desired transient pulse shape can, in principle, be obtained by appropriate frequency-domain programming, which opens the way to a novel type of optical memory.