OK, I have changed some of the G code near the end of the file as follows
G00X-0.065Y-0.025
M98 P#100
G00X-0.13Y-0.025
M98 P#10
G00X-0.20Y-0.025
M98 P#1
M950 (This is the macro that I wrote. See below)
G92.1
M05
G00 G90 X0 Y0 Z0
M01
M98 P200
M02
O0
G00 Z0.01
G91
G00 X-0.0424 Y-0.0229
F12.0
G90
Macro
a = GetVar (1)
Print a
b = GetVar(10)
Print b
c = GetVar(100)
Print c
d = GetVar(1000)
Print d
a = a+1
If a = 10 Then a = 0
If a = 0 Then b = b + 1
SetVar 1, a
Print a
If b = 10 Then b = 0
If b = 0 Then c = c+1
SetVar 10, b
Print b
If c = 10 Then c = 0
If c = 0 Then d = d+1
SetVar 100, c
Print c
If d = 10 Then d = 0
SetVar 1000, d
Print d
I put the print statements in to see what was happening and it runs fine when called but in the VB assist window it prints the values.