Cicode Programming Reference > Cicode Function Categories > Alarm Functions Introduction > AlarmSumSet


This command is deprecated in this version of CitectSCADA. Use the AlmSummarySetFieldValue command instead.

Sets field information in an alarm summary entry. You identify the alarm summary entry by the Index, returned by one of the alarm summary search functions.

By embedding this function in a loop, you can change field data in a series of alarm summary entries. To start from the oldest entry, call the AlarmSumFirst() function to get the index, and then call AlarmSumNext() in a loop. To work back from the latest entry, call AlarmSumLast() and then AlarmSumPrev() in a loop.

You can also get the Index from the AlarmSumFind() function, which finds an alarm summary entry by its alarm record identifier and time of activation.

When the Alarm Server is not in the calling process, this function will become blocking and cannot be called from a foreground task. In this case, the return value will be undefined and a Cicode hardware alarm will be raised.

Fields of an appended alarm can only be set using this function or the replacement function AlmSummarySetField().

You can use user events to keep a record of logins, or control operations that you need to display in the alarm summary etc. The fields of UserEvents need to be set immediately after creation using this function. These entries in the Alarm Summary cannot be filtered from the summary in an AlmSummaryOpen() browse session.


AlarmSumSet(Index, sField, sData [, ClusterName] )


The alarm summary index (returned from the AlarmSumFirst(), AlarmSumNext(), AlarmSumLast(), AlarmSumPrev(), AlarmSumAppend(), or AlarmSumFind() function).


The name of the field in which data is to be set:


Alarm acknowledged time


Alarm comment

OffMilli (for time stamped alarms only)

Alarm millisecond off time


Alarm OFF time

OnMilli (for time stamped alarms only)

Alarm millisecond on time


Alarm ON time


Alarm state


The new value of the field.


Specifies the name of the cluster in which the Alarm Server resides. This is optional if you have one cluster or are resolving the alarm server via the current cluster context. The argument is enclosed in quotation marks "".

Return Value

0 (zero) if the alarm summary entry exists, otherwise an error is returned.

Related Functions

AlarmSumGet, AlarmSumFirst, AlarmSumNext, AlarmSumLast, AlarmSumPrev, AlarmSumFind


See AlarmSumFirst

See Also

Alarm Functions