Using Include Files in Routines

Include files in IDL are .PRO files that contain IDL code and are designed to be included within other programs at compile time.

You can include these files within your routines using the @ character. For example, assume you have a file named myroutine.pro containing the following statements:

PRO myroutine

...code...

@myinclude.pro

...more code...

end

When IDL compiles myroutine.pro, it will automatically read in all of the IDL code within myinclude.pro and embed it within the program, just as if the code had been directly included within myroutine. When the end of the file is reached, compilation resumes at the line after the @.

Notes

See Also

Overview of IDL Program Types, Batch Files, Special Characters