How to trigger a process based on button selected by user in Assisted Automation

I’ve injected multiple button to a page via JavaScript.

How can i know which button is clicked by user and so based on that trigger different sequence in workflow.

Note: This is a use case for attended automation.

Hi @AnoopMP

Have you tried using Get Attribute or Wait Attribute activities?
They might come useful in this case.

Hi @loginerror,

The following js is used to create that button. So i guess get Attribute won’t work in this case


Try by using Get Source Element Activity.

It will return the uielement which the user triggered. So that you can know the button by using uielement.



Right @MAHESH1 .That works. :slight_smile:
Got the right method after playing around for some time.

Here’s what i did for this use case in case anyone else is also facing the same issue,

1)Under Monitor event activity, i added Click Trigger activity for all the required buttons.
2)After that i added a sequence having the Get Source element activity with the output as “ChoosenButton”.
3)Added an If condition with condition as “ChoosenButton.Selector.ToString.Contains(“button_name”)”.
4)Continue with Then and Else cases mentioned.