Not sure if it would work but you could use screen4 to make a button on your screen, then set this button up to do the Gcode that you want and set a hotkey for it to match your pendant button. You may run into problems if you replicate a hotkey that is already used so try with caution.
Hood