Skip to main content
Question

Validating FIXED_DATA5 parameters

  • February 8, 2025
  • 0 replies
  • 40 views

ellenlee619

What is the best way to validate that the parameters input by the user are valid? For example, say that I have a parameter “n_rows” that needs to be an integer greater than zero. Should I check this upon initialization of the DLL (case 8)? If the input is invalid, should I then change the corresponding FD->param[i] it to be a valid value (e.g., if the user input 0 then change it to 1)? Or is this a bad idea? The example files state that the DLL should only modify FIXED_DATA in case 7, when Zemax is asking for safe data. Thanks