a vehicle transmission having shifting elements and a parking brake for locking a drive train output and a method for controlling the transmission . activation of the parking brake depends on a driver &# 39 ; s control action . deactivating the parking brake , when the vehicle is on a slope greater or lesser than a preset value and depending on the slope , a combination of shifting elements or frictionally slip , such that the output rotates against the strain on a parking brake locking element , caused by the slope , to partially eliminate this strain . next , one of shifting elements engages locking the output . the parking brake is then released and finally , the engaged shifting element is disengaged in a regulated manner , such that the output can be driven according to the driver &# 39 ; s control action .