uncontrolled revving when idling, engine failure on 1992 BMW 325i

the car drove fine until i got caught in traffic and was idling with my foot on the brake, however, the engine started 'jumping' as if i was pressing the accelerator. i also noticed the rpm's jumping as it did, and then the engine died. i turn the ignition again and the car started, but stalled after a few seconds, so i decided to turn it on again and give it gas, but the car would roll slowly and then give on me again.
any ideas?

Asked by for the 1992 BMW 325i
Possibly the throttle position sensor is failing but you need to have a tech diagnose this before changing parts as when the throttle position sensor fails it will run poorly.
1 answer