The MODIFYSETTINGS keyword in the macro language can be used to change data within the settings files, or the configuration files in ZEMAX.  Normally, this is used in conjunction with the GETTEXTFILE keyword, as one of its inputs is the desired configuration file.

For graphic type windows, a little trick may be used.  This trick involves reloading the same lens file after making any changes to the analysis specific configuration file located in the main ZEMAX directory (for example, LSH.CFG for the Shaded Model).  If the lens is loaded without a session file, then the settings found in the analysis’ configuration file are used to update the desired window number.

REFERENCES

ZEMAX Optical Design Program User’s Guide, ZEMAX Development Corporation