How to pass "previous " object in eventQueue() through Business rule and retrieve in Script Action..

sumitjumale
Kilo Contributor

Hi All,

I need to pass "previous " object in eventQueue() through Business rule and retrieve in Script Action. I am able to pass current object.. but I coudnt retrieve   previous object wirh event.parm1.

Please suggest.

Regards,

Sumit Jumale

20 REPLIES 20

This should work because Script action has event object access. We can pass event param1 as string. We can get that in script action.

 

Please encode previous object as pass as event param1.

In the Script action, decode the string.

Anurag Tripathi
Mega Patron
Mega Patron

Havent checked the whole thread but i dont see anything challenging here. Business rule must have previous object(Asynch doesnt have it) gs.eventQueue('EVENT NAME',previous,'', '');


-Anurag

Except, I believe, he wants access to both the current AND previous record values.   The method gs.eventQueue() will only pass one argument as an object, the rest are strings.




-Brian


yes Brain..


I need to pass both, current and previous.


changes(),changesFrom(Object), changesTo(Object) is not working for ur above mentioned code..



Hi Sumit,



Please copy/paste the script you are testing here into the thread.   I wrote and tested the previous version successfully just days ago, so I know the method should work in this stripped down version.



I had no issue with the change() method working for elements then, so I'm guessing you might have a syntax issue.   Pasting your code will help to determine.




Thanks,


-Brian