Hello,
I am trying to get a jointtarget from an array but the name of the array is in a string. I need to pull the first target and move to it to make sure it is safe.
Code
MODULE MainModule
CONST jointtarget 0614_1550{3} := [[[106.747854, 18.262021, 1.463337, 15.037443, 53.346470, -94.508325], [9E9, 9E9, 9E9, 9E9, 9E9, 9E9]],
[[106.747874, 18.262186, 1.463300, 15.037422, 53.346501, -94.508289], [9E9, 9E9, 9E9, 9E9, 9E9, 9E9]],
[[106.747880, 18.262244, 1.463287, 15.037415, 53.346512, -94.508277], [9E9, 9E9, 9E9, 9E9, 9E9, 9E9]]];
PERS string sTargetName:="0614_1550";
Proc Main()
var jointtarget jtCurrTarget;
!Find a way to get first target from array <---------- Need help here
MoveAbsJ jtCurrTarget,v1000,z50,tool0;
ENDPROC
ENDMODULE
Display More
I have tried GetDataVal and Late binding. What makes this tough is that the jointtarget array name changes based on what file is loaded and the array dimension changes as well.
Any help is greatly appreciated.