Why do the lights go out on your car when you switch from dip to main beam?

I'm not sure what you mean by "dip" and "main", but if you mean when you switch from low beam to high beam, then the problem most likely is in your turn signal lever. There may be a dead area in between pulling it back (low beam) and pushing it forward (high beam). I had this problem on a '98 Grand Marquis. Make sure the lever is all the back on low beam until you get it repaired. I would not recommend switching to high beam before then.

try replacing one of the bulbs on one side first, you may just have the high-beam element burnt out in both bulbs