Skip to main content

ZPL function to get the number of rows in the Merit Function Editor ?

  • September 28, 2019
  • 1 reply
  • 111 views

Forum|alt.badge.img
   Is there a ZPL function that returns the number of rows in the MFE?  (ZOS-API has MFE.NumberOfRows, but I don't see this for the macro language.  )
   I want to insert a new blank row at the very end.
   This didn't work:  InsertMFO  N                  where N is a big number, chosen to be greater than the number of rows.

Thanks for your time.

Best regards,
John
Did this topic help you find an answer to your question?

1 reply

Chris Normanshire
Zemax Staff
Forum|alt.badge.img+2
You can return the number of operands in the merit function editor (MFE) by using the GETSYSTEMDATA ZPL keyword. GETSYSTEMDATA retrieves lots of system specific data and stores it in one of the pre-defined arrays VEC1, VEc2, VEC3 or VEC4. You can then retrieve the data using the VECx() functions. The number of operands in the MFE is stored in position 28 of the array. The code snippet below shows how to access this data.

GETSYSTEMDATA 1
NumMFOperands = VEC1(28)

Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings