Try OpenEdge Now
skip to main content
BPM Events User's Guide
Understanding BPM Events : The XML event : Accessing message properties

Accessing message properties

Properties can be accessed using the getProperty method. The properties Origin, Destination and Description can be accessed from the purchase order xml event, as shown below:
rule po_activatedShip
activated by
    msg of po:purchaseOrder["po:shipTo/po:state = 'NY'"]
then {
    println("============== po_activatedShip =============");
    println("Received JMS Event, shipping state is: " + msg["po:purchaseOrder/po:shipTo/po:state"] + " and month is: " +", Origin: "+msg.getProperty("Origin")+", Destination:
Description: "+msg.getProperty("Description"));