Toyota Repair: 1999 toyota camry shut off, toyota camry, several miles


Question
Just purchased 1999 toyota camry.   while driving when I put on brakes to slow, the car started vibrating and cut off.  All lights on dashboard flashed.  After 3-4 attempts, car started up and ran ok for several miles.
Any idea what it could be?

Answer
You said it stalled and then ran ok for several miles,what happened then? Is it running now, if not what is it doing now, is it turning over but not starting up? I need more information, also if the engine is running does the che4ck engine light stay on?