Hang on boot

My main PC seems to be hanging on bootup. It gets past POST fine then goes to a black screen with a flashing _ as if it was in DOS/CMD line. Pushing buttons does nothing. There’s no error codes (being a Dell XPS 420, it has random numbers on the top of the PC to show error codes) or beeps.

However Windows Sidebar loads (is this separate to the OS?)

I’m currently running memtest but I’m guessing this is a possible Windows corruption and fail to boot?
I seem to recall it wouldn’t switch off or shut down last time I tried to and even pushing the off button and reset switch did nothing so it had to be turned off at the wall to be turned off.

Any ideas?

After running memtest, it seems to have sorted itself :s It came up with the Windows has shutdown badly - what do you want to do screen.