Morning Tracey
Welcome to the Forum
To run your engine needs Air, Fuel, Compression and if petrol a spark. So the fuel pump and its controlling relay and fuses need checking fuel delivery/testing. As does the whole delivery from the tank to the engine, fuel pressure needs checking at the fuel rail. The fact it happened so fast I would suspect a Fuse or Relay possibly a Crank sensor or fuel pressure sensor
To save a lot of time a Diagnostic session using a BMW capable scanner would help pinpoint te issue
Dave