why does my car die when i press the brake on 1994 Pontiac Sunbird

it will drive but when i press on the brake it dies out. The car did sit in the garage for about a year without being driven

Asked by for the 1994 Pontiac Sunbird
Need to know-Does it do this in park or just when in gear?
just when in gear
Can you drive the car at all or does it stall immediately when shifted into a gear? We are getting there, need to know this!
it drives for about 10 minutes or so, the when i come to a complete stop it just dies out but if i continue driving without braking it doesnt die out
Defective torque converter lockup solenoid is the first suspect!!! Have it checked out by your mechanic IF you can get it there! Not a real expensive repair. This part dosent let the torque converter unlock, kinda like not pushing the clutch in on a stick shift when stopping, the engine will stall. Normal to be able to drive it for awhile before it acts up.
thanks, i will have it checked out...