Transfer code from Micro:bit back to PC

Hi. I have the problem that I no longer have my code on the computer. On my Micro:bit the code is running and I would like to load it back to the computer to continue editing. is this possible?

thanks for your help.
Simon

It probably acts as a drive, so if on Windows you opened Files and looked at the Micro:bit’s files, it might be there as a file and you can upload it to your account!

If it’s the same as Arcade devices, you can import the CURRENT.UF2 file on that drive.

The micro:bit isn’t really a flash drive and the .hex is “converted” to flash memory rather than being copied in its original form (see here).

I’m not sure there’s a way to recover a MakeCode file, but you may take a look at uBitTool, which is described here: https://support.microbit.org/support/solutions/articles/19000117904-how-to-get-the-current-program-off-the-micro-bit. It appears to allow recovery of Python files.

Bill