The function LoadPERefSpecs loads the reference spectra from the file FName into the particle editor. The file FName must be a spectral collection (see the section Spectral Collection Data Format for details).
The function returns the number of spectra loaded or a negative number indicating an error. If the returned number is zero this most probably inicates that the loaded file does not contain any spectra. Please note that the particle editor must be active before you can execute this function.
The function returns the following error codes:
≥0 ... everything is OK, the reference spectra have been loaded
-1 ... the file FName does not exist
-2 ... the particle editor is not active (use ShowParticleEditor to open the particle editor)