A simple quantum mechanical system consisting of a particle in a one-dimensional impenetrable box is considered in a situation wherein the wavefunction is subjected to moving boundary conditions. A method of approximating the wavefunction is presented and applied to a simple example.