1999 Honda Accord V6 starting problems

I was on the freeway when the engine lost power and the dashboard lights came on. After about 3 seconds everything was fine. Now after short trips, about five miles, if I turn off the car, when I try to start it, it turns over like it should but will not stay on. After a few minutes, everything will work fine. Dealer said there is nothing they can do about it, because there are no error codes. The computer was changes about 3 months ago.