Thank you Joe!
Its too simple or difficult way. I think will good if Mach designers insert this possibility (I mean redefinitions of G-code) to Mach4 or 5 etc.
As solution, I think maybe add to the button "load Gcode" VB script, for to find g27, and change it to M3 code.