# Using the Event Rules Form

Navigation: Working with Nx Witness > Events Rules > # Using the Event Rules Form |

The form opens in the lower half of the Event Rules dialog when you select a rule in the list or when you click the Add button. Often it includes parameters that are not available in the Event Rules list.

Adding an Event Rule from the Form

1.Click the Add button (or right-click on an existing rule in the list and click New in the context menu). The form will open and a new line for the rule is added to the list.

2. Select the Event to be monitored and the Action to execute when that event occurs. Each requires one or more of these parameters:

For Events

•When – click on this field in the form (or the Event field in the list) to select from the menu of events.

• Starts or Stops – see below.

•Device(s) – click on the At field in the form (or double-click on the Source field in the list) to select one or more devices.

For Actions

•Do – click on this field in the form (or the Action field in the list) to select from a menu of actions.

•Device(s) – click on the At field in the form (or the Target field in the list) to select one or more devices that will execute the action. At least one device must be selected for a rule to be valid.

•User(s) – click on the To field in the form (or the Target field in the list) to select one or more user roles as recipient of the action. At least one user must be selected for a rule to be valid.

•Schedule – click on this button to open a calendar for "Setting up Schedule for Tracking Events".

•Comments – enter any desired remarks.

•Interval of action and Fixed duration – see below.

3.Click OK to apply changes and close the form.

Click Apply to accept changes and keep the dialog open.

Click Cancel to close the dialog. A confirmation dialog will prompt you to either Apply or Discard changes, or you can click Cancel to return to the Event Rules dialog.

Note: If one or more rules are not correctly defined, you will get the error message "Some rules are not valid. Disable them?"

Click Yes to disable the invalid rules. Invalid rules will remain in the list but their On checkbox will not be checked.

Click No to allow invalid rules to be active (On checkbox will be checked and rule will be highlighted in red.)

4.In the Event Rule list, set or clear the On checkbox to enable or disable the rule.

IMPORTANT: Make sure notification for the event type is turned on in Global Notifications.

Using Selection Lists in Event Rules

Event rules use selection lists to choose devices and users. Selection and filtering behavior, described in the next topic, is consistent in both.

Continuous or Instant Events

Some events may be continuous, some can only be instant, and some may be either (generic or analytics events).

Continuous – Events that can occur continuously, such as an motion on a camera, require a state definition of either Starts or Stops.

Instant – Events that occur instantly, without duration, such as a device being disconnected or a server starting. For generic and analytics events, instant events are labeled Occurs.

Instant, Interval or Fixed Duration Actions

The following parameters are available for most actions, depending on their intended behavior.

Interval of Action – Check this box to limit the frequency with which an action will occur in response to an event. E nter an integer value (1 - 999) in the No more than once per field, and select a corresponding time increment (sec, min, hrs, days). This feature is useful, for instance, with an action like show notification where the triggering event may be continuous but it is only necessary to be notified periodically.

Instant – Uncheck this option so the action will execute every time the event occurs.

Fixed Duration – Check this option to specify how long an action will last, typically in response to a continuous event. Enter the duration, in seconds. Zero is not a valid entry, and depending on the action there may be an upper limit to the duration.