Using References Without Initialization

The following steps are necessary to generate code for references without initialization. The sequence of the steps can be changed, except for the last one.

  1. Create the references you need.
  2. Specify your model.

    Note

    While you specify your model, you  must make sure that each explicit reference is initialized before it is read.

  3. In the project settings of your project, activate the Allow References without Init Valuecode generation option.
  4. Ignore or revoke the global promotion of the following warning.

    WMdl822 – read access to reference without init value "<reference name>" possibly prior to initialization of reference

  5. Generate or build code for the project.

See also

Specifying a Reference

Adjusting the Project Settings

Component Manager – Revoking a Promotion (Monitor Window)

Component Manager – Revoking a Promotion (Configuration Windows)

Project Editor – Generating Code

Project Editor – Building/Rebuilding Executable Code

Project Editor – Code Generation Options

Initialization of Explicit References