User-defined objects are compiled code and have the file extension .dll. This extension shows that the code is a 'dynamic link library', which an executable program (.exe) or other dll can call and execute.
Once such code is written, it must be compiled with the proper switches. An appropriate command line, executed from a command shell, is:
$ LF95 <sourcecode>.f90 –win –ml msvc –dll
This will generate the “source.dll” file, which can then be moved to the appropriate directory, generally under {zemaxroot}\ Objects \ DLL \ .