I executed with UE v188.8.131.521 your steps (with using the hotkeys and not the mouse) while quick recording a macro. The recorded macro code was:
The command Bottom is definitely a bug. In causes the cursor to move to bottom of the file and because the selection mode is not enabled, the selection is dismissed. In previous versions (UE < v14.20) no command Bottom is recorded. The command Bottom is also total nonsense because the cursor is at top of the file after selecting entire file content with Ctrl+A. I reported this bug of the macro recorder to IDM by email.
Use following macro code:
Well, I don't know why you do not simply delete the file instead of deleting just its content, but the macro does now what you want.
This bug of the macro recorder was fixed with UltraEdit v16.00.