Preparation of a specific quantum state is a required step for a variety of proposed practical uses of quantum dynamics. We report an experimental demonstration of optical quantum state preparation in a semiconductor quantum dot with electrical readout, which contrasts with earlier work based on Rabi flopping in that the method is robust with respect to variation in the optical coupling. We use adiabatic rapid passage, which is capable of inverting single dots to a specified upper level. We demonstrate that when the pulse power exceeds a threshold for inversion, the final state is independent of power. This provides a new tool for preparing quantum states in semiconductor dots and has a wide range of potential uses.