The effect of the solar wind on the spectrum of cosmic rays accelerated in the Galaxy is studied. The coefficient of cosmic-ray diffusion in the interplanetary turbulent magnetic field is assumed to be independent of the particle energy and a power-law function of the distance from the Sun. The particle spectrum at the heliospheric boundary is specified as a power-law function of the total particle energy.