cancel
Showing results for 
Search instead for 
Did you mean: 

Close a Popup without an Action

Former Member
0 Kudos

Hi there,

I created a popup in which you see a progressbar. Now I want to close the window after a defined time. Is there a way to connect a timer or make a kind of condition, that the popup will close after 5 sec or so?

Thanks

Marcus

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi Marcus,

Hope i've understood ur problem correctly ! If i have, the following solution must work -

1) Place your progress bar in the pop-up.

2) Place a timed-trigger UI element, "trg_Timer" in the layout of that pop-up view.

3) Create an integer context attribute, "intCounter" in the pop-up for the count down and bind it to the timed trigger Ui element.

4) Create an action "onTimeComplete" in this view and bind to the "onAction" property of the timed trigger.

5) Inside the "wdDoInit()" of the pop-up, set intCounter = 5. This means the timer will start as soon as the pop-up window opens.

6) Inside "onTimeComplete", write a code that calls method in some custom controller, say "mTimeCompleted()".

7) In "mTimeCompleted", fire an EVENT, "mTimeCompletedEvent" using the wdThis.wdFireEvent() method.

😎 In the main view that opened the Pop-up window in the very first place, there should be an event handler that subscribes to this "mTimeCompletedEvent".

9) Inside the above event handler, close the pop-up.

regards,

Navneet.

former_member193545
Active Participant
0 Kudos

Hi

You can place a timer in the popup iview and then connect it to an endpoint, you can use the tick event to fire the endpoint.

Jarrod Williams

Former Member
0 Kudos

Hi,

well it works with the timer and the point in the popup. but the popup doesn´t close completly, there are still a kind of light grey shadow of this popup. Is it a buck? Or must I customize somethingelse.

Thanks

Marcus

Former Member
0 Kudos

Hi Marcus,

I never did something else before, but I would try a timer and maybe a guard condition, so that every 5 seconds the timer sends a signal and if your condition is true it will close the popup. Does any value change, if the progress is completed? - Maybe you can use this changing value for your guard condition.

I don't know your exact model, so I have to guess.

Best Regards,

Marcel