hexagon logo

Tip object

Hi,

I am trying to get A angle of tip for script.

From help:
"Tip.A
Returns the A angle of the tip. Read-only Double."

I have no clue how to retrieve data. How I can A angle of current tip?
  • Thanks, nice piece.
    I do understand logic of this function and it looks better than my piece of code. From other hand I do not use any single function in my scripts and I didn't have any working function and that is probably because when I started programming I didn't have any success on creating functions. At this time I'm nearly running out of ideas and when I will run out of ideas then I will start optimisation of scripts then I will try functions again.
  • Paste this into your module and try calling MsgBox AngleA(Cmd.GetText (ID, 0)) . You REALLY should use functions in anything that isn´t trivial. It´s not difficult either, if you´ve failed it´s just some minor syntax error.

    Function AngleA(Name As String) As Integer
    Dim Temp() As String
    Temp = Split(Name, "A")
    Temp = Split(Temp(1), "B")
    AngleA = CInt(Temp(0))
    End Function
  • Well... tried, tried but.... I can't understand what exactly I can't understand. I done copy and paste to my script "Sub Main" but I didn't overcome error.
    Could you please to do little script which scan CMM program and display angles A of tip? Maybe it could help me understand where is problem.

    I'm receiving message with syntax error but I can't see any error. I'm using pc dmis 15.1, could it be problem for run of functions?