Including Resources Using Multiple Resource
- To include resources that have already been developed and tested and do not need further modification.
- To include resources that are being used by several different projects, or that are part of a source code version-control system, and thus must exist in a central location where modifications will affect all projects.
- To include resources that are in a custom format.
- To include statements in your resource file that execute conditionally at compile time using compiler directives, such as #ifdef and #else. For example, your project may have a group of resources that are bracketed by #ifdef _DEBUG ... #endif and are thus included only if the constant _DEBUG is defined at compile time.
- To include statements in your resource file that modify resource-file syntax by using the #define directive to implement simple macros.
- Place the resources in anRCfile with a unique filename. (Do not useprojectname.rc, since this is the default filename used for the main resource script file.)
- From the Edit menu, choose Resource Includes.
- In the Compile-time directives box, use the #include compiler directive to include the new resource file in the main resource file in the development environment. The resources in files included in this way are made a part of your executable file at compile time. They are not directly available for editing or modification when you are working on your project's main .RC file. You need to open included .RC files separately.