You can use the GRP() function to do what you describe. GRP(0) returns total number of elements in current, active group GRP(1) returns first element number in the current, active group GRP(GRP(0)) returns last element number in the current, active group
Some info can be found on page 85 of the SmartCAM Customization Guide. // Production_Milling 11.5 Windows 10/16/98 16:52:40 Macro File // C:\SM9\SHARED\sysmcl\WT.mcl // CREATED: 10/02/02 // // CHAIN[EL=GRP(1), PJ=0] SPLIT[EL=GRP(1), LC=2, GW=.12, LN=.5, DS=0, FR=0] LEAD_IN[EL=GRP(1)", AN=-90, DS=.2, LC=0, TY=0, CS=0, RP=0, MO=0] LEAD_IN[EL=GRP(GRP(0)), AN=-90, DS=.05, LC=1, TY=0, CS=0, RP=0, MO=0] ============================================= Fred Lauzus, CAM Programming Coordinator High Steel Structures, Incorporated mailto:[EMAIL PROTECTED] http://www.highsteel.com ============================================= -----Original Message----- From: Steve [mailto:[EMAIL PROTECTED]] Sent: Wednesday, October 02, 2002 4:59 PM To: SmartCam user Group Subject: [mfg-smartcam] macro help I am trying to make a macro that will make a tab on a sheet metal part and then create a lead in and a lead out. The cutouts will always be cutting counter clockwise. Sequence of recording 1) chaining the group at the starting element I want to have the tab 2) split the starting element with the mouse option (not left or right) making a .060 tab <gap width .120> 3) lead in is -90 degrees .200 long 4) lead out is at -90 degrees .050 long How do I make the elements variables? // Production_Milling 11.5 Windows 10/16/98 16:52:40 Macro File // C:\SM9\SHARED\sysmcl\WT.mcl // CREATED: 10/02/02 // // CHAIN[EL="Edit name elements", PJ=0] SPLIT[EL="Edit name elements", LC=2, GW=.12, LN=.5, DS=0, FR=0] LEAD_IN[EL="Edit name elements", AN=-90, DS=.2, LC=0, TY=0, CS=0, RP=0, MO=0] LEAD_IN[EL="Edit this is the last element in group ", AN=-90, DS=.05, LC=1, TY=0, CS=0, RP=0, MO=0] **Note---the CHAIN, SPLIT, & 1st LEAD_IN elements are the same and are the 1st element in the group the 2nd LEAD_IN statement element is the last element in the group Thanks Steve ATM ====================================================================== To find out more about this mailing list including how to unsubscribe, send the message "info mfg-smartcam" to [EMAIL PROTECTED] ====================================================================== ====================================================================== To find out more about this mailing list including how to unsubscribe, send the message "info mfg-smartcam" to [EMAIL PROTECTED] ======================================================================
