Ok so i now have
SetCurrentTool(GetSelectedTool())
msgbox(CurrentTool)
If CurrentTool <> 1 Then
SetVar(1000,GetToolParam(1,2))
Msgbox"" & GetToolDesc(1) & " Offset = " & GetToolParam(1,2)
End If
If CurrentTool <> 2 Then
SetVar(1000,GetToolParam(2,2))
Msgbox"" & GetToolDesc(2) & " Offset = " & GetToolParam(2,2)
End If
The code is not setting CurrentTool, I added the msgbox on line 2 so i could verify this and it shows a blank message, the reason i checked it was because when the macro runs it shows two messages sequentially - tool 1 then tool 2 regardless of tool chosen in the M6 line