while driving, my gas guage went to empty and the check motor came on and beeped on 2003 Dodge Ram 1500

as i was going down the road, my car beeped, looked down at the guages and my gas guage had quit and the ck engine light came on. pulled over and turned ignition off and then restarted, gas guage working now but engine light still on. drove about 2 miles and gas gauge quit again and i repeated what i did earlier and got same result

Asked by for the 2003 Dodge Ram 1500
scan codes and post so we can adv