SCS.General.ActivateEvent not working

Hello,

<input type="button" value="Door F123 ActivateEvent" onclick="SCS.General.ActivateEvent('Door F123')" />
<input type="button" value="Door F123 Normal" onclick="SCS.Events.All.SOMESERVER.All_EventTypes__Corporate_.Door_F123()" />

The first button does not work but the 2nd one does. Any idea why?

Also, what is the Difference between SCS.General.ActivateEvent and SCS.General.ActivateEventNotify?

Any is there any tips to debugging such HTML view items scripts? Maybe by using javascript to write errors to a div displayed on the HTML page?

Maybe it wasn’t clear, but this is an HTML page displayed in the Smart Client. It seems like the Javascript API to trigger events is kinda broken.

Milestone Development will start an investigation.

I have asked experts regarding the issue. Please see below comments from them.

-—

The ActivateEvent does work, however it needs fully qualified names to identify the correct event. That is also why the second button works because it uses the full name.

In this case the correct name to use with ActivateEvent should be ‘All EventTypes (Corporate).Door F123’.

The difference between ActivateEvent and ActivateEventNotify is that ActivateEventNotify sends out a notification internally in the SC which makes sure that the event is selected in the Event panel in the left side of the SC (to show that the event is/has been used).

We don’t have expert knowledge about javascript debugging, but in most modern browsers you can activate a debug window to debug the page. However I believe this issue will be very difficult to debug because I don’t think the ActivateEvent will provide any return information. Part of the debug complexity is because of the communication between the script in the page and the hosting application, so unfortunately I think it will be very difficult to debug for a partner.

Amazing, thanks a lot!