cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
chris72
New Member

How to deal with a sudden logout on a website?

Hi there,

 

I've been using Power Automate Desktop for about 2 weeks now to fill out a multi-page, extensive web form. I have always changed and expanded my flow for this. Filling out text fields, uploading files, marking checkboxes, etc. all of this works quite well by now. Although I need help now.

 

It happens very rarely, but the website that this form is on sometimes suddenly and unexpectedly logs me out. That prevents me from really leaving it unattended. So I need a way to be able to log in again at any time and then continue the flow.

 

As soon as you are logged out, the "login dialog" appears, in which my user is already selected. All I have to do is enter my password (or select the data stored in the browser) and click on Log in. I think its easy to handle the login dialog once it appears... But how do I prepare PAD to handle this at ANY time?

 

Hopefully one of you can explain to me how to do this. Where do I have to enter what and how do I start?

 

Thanks for the help! 😀

 

Chris

1 ACCEPTED SOLUTION

Accepted Solutions

You could make loggin in an error subflow.  So, you set up a subflow that says:

Enter password, click submit button

 

And then you wrap the rest of your flow in an On Error Block.

And you point the error block to the OnErrorSubflow.

View solution in original post

4 REPLIES 4
MichaelAnnis
Super User
Super User

There is an "If web element exists" action.  So:

If password element exists, run login steps to get back to web form entry

End (IF)

Complete web form.

Have this before every web form entry, and it might add 1/2 a second to each one, but it will solve your problem.

 

Best of luck!

Thank you for your answer Michael!

 

As I said, the logout rarely occurs. Sometimes I work with it for several hours and don't even see the login dialog. When the login dialog was last displayed, I immediately made a few notes. Window names, texts on the page, names of the fields, etc. I can use that now...

 

My flow currently has about 80 steps. Should I really incorporate this If-Then every 5 or 10 steps?

 

That would be like repeating CSS, header, footer and sidebar over and over again instead of outsourcing it. That sure works, but is it nice?

 

Is there no central, one-off solution for this?

 

Thanks for your help!

 

Chris

You could make loggin in an error subflow.  So, you set up a subflow that says:

Enter password, click submit button

 

And then you wrap the rest of your flow in an On Error Block.

And you point the error block to the OnErrorSubflow.

chris72
New Member

Thank you Michael!

 

that's 2 options I can play with. One of them will sure do it. 😀

 

Chris

Helpful resources

Announcements
MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

Power automate tips 768x460 v2.png

Restore a Deleted Flow

Did you know that you could restore a deleted flow? Check out this helpful article.

Microsoft Build 768x460.png

Microsoft Build is May 24-26. Have you registered yet?

Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.

May UG Leader Call Carousel 768x460.png

What difference can a User Group make for you?

At the monthly call, connect with other leaders and find out how community makes your experience even better.

Users online (3,233)