Is it possible to create an Alarm without a hardware (item).EnvironmentManager.Instance.SendMessage( new Message(MessageId.Server.NewAlarmCommand) { Data = alarm });

An Alarm must have a source. You see this also when setting up Alarm Definitions in the Management Client, that you cannot define an Alarm Definition without having a source involved.

The source for an alarm can be any item in the VMS, it does not have to be a camera. You could have a user-defined event with a suitable name designated as source. If you do not have anything, neither in devices nor events, that would fit as source, a possible workaround is to set the Management Server as source.

In order to see for myself that the workaround works I modified the Library Event Generator sample like this:

private void OnSelect(object sender, EventArgs e)

{

                        \_item = Configuration.Instance.GetItems(ItemHierarchy.SystemDefined)\[0\];

                        \_buttonSelect.Text = \_item.Name;

}

Thank you, that helped me a lot!