Jeep grand cherokee 1999 stalls while driving

jeep grand cherokee 1999 stalls while driving. replaced crankshaft sensor. Check engine light indicates oxygen sensor issue. After 5 to ten minutes car starts again, most of the time. When the car fails, engine cuts out and gas gauge points to empty. Only starts when the gas gauge functions properly. still having this problem, please help

It sounds like there is a issue with the connection to power. There may be a problem with the ignition switch causing the trouble.

So when the gas gauge points to empty will the jeep still crank over?