Thanks for the re –formatted code and the free spaces-

sorry to hear about your failing psychic capabilities so here are some details-

I have been running the test code on a live machine and expect to see the torch:-
1 Travel down to the surface of the material
2 Take up the free play of the floating head
3 Retract back to the surface (which should now be z 0)
4 Go to pierce height
5 Torch on
6 Pierce delay
7 Go to cut height
8 Start cutting.
The free play between the torch touching the material and the limit triggered is measured at 3.6mm. (This becomes my zoffset parameter in the code-UserDRO (1003))
The first problem is my mistake in that the Torch on command should be before the Pierce delay command in the code-easy fix.
The second problem is if I use the zoffset (3.6mm), pierce height of 2mm and cut height of 1mm and run the code the actual pierce height on the machine is high and subsequently the cut height is high, although the measured difference between the two is 1mm as expected.
I can get the correct pierce height-cut height by reducing the zoffset figure but I must have something wrong!
I have rechecked the zoffset measurement and the z axis calibration and both are correct. Could the problem be associated with the G28.1 command? I notice that the z axis backs off from the switch at the end of the homeing sequence and so I have the z axis home set to auto 0 but is this conflicting with the G92z0 in the macro and resulting in an incorrect offset?
Tony