Handling sources

The same events can occur at different points in a program. The source of an event is described in the programming by the "Source Info" and sent as well when transmitting.

The SourceInfo consists of three parts (see Events).

The source is also specified when creating the event in both programming languages.


The FB_TcSourceInfo is used for this in the PLC.

Handling sources 1:

This is parameterized accordingly before Create()/CreateEx() is called:

Handling sources 2:

Alternatively a zero can be assigned to the corresponding parameter on calling Create()/CreateEx() in order to use the internal standard source information of the PLC. If no explicit SourceInfo is then specified, the symbol path is output where the event is instanced as SourceName and the object ID of the PLC instance as SourceID.

Handling sources 3:


TcSourceInfo is used in C++ and can be transferred, for example, in the following way with CreateMessage()/CreateAlarm():

Handling sources 4:


This SourceInfo can be shown accordingly in the LoggedEvents window:

Handling sources 5: