Example of the SWEAInvokeMethod Notification

The following code is an example usage of the SWEAInvokeMethod notification:

this.AttachNotificationHandler(consts.get("SWE_PROP_BC_NOTI_GENERIC"), function 
(propSet){ 
var type = propSet.GetProperty(consts.get("SWE_PROP_NOTI_TYPE"));    
if (type === "SWEAInvokeMethod"){    
if (argsArray[1] === "NewRecord"){    
// Ah so there's going to be a new record that has happened as a chain.    
// Let's set a property so that we can do an AddMethod on this NewRecord,     
// and extend it to our liking    
this.SetProperty ("isChained", true);    
}    
}    
});