cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
pcand1001
Helper I
Helper I

How can I speed-up the desktop flows execution

Hello,

When I start a desktop flow, I get the flow started notification.
This flow is sending the left window key, then type a string, then hit enter, wait for a window, type some text and start doing other things.
I have to wait 7 seconds for the first action to execute, then 5 seconds for the second action, then 7 seconds etc.
If I execute these steps by hand, I can do it much faster than the flow.
How Can I speed-up the execution?
See flow bellow.
Thanks,

Philippe

Snap4.png

1 ACCEPTED SOLUTION

Accepted Solutions
pcand1001
Helper I
Helper I

Unbelievable but I could resolve the issue by uninstalling the Win10 build-in Edge browser using command line and reinstalling it from the regular installer. Now AnnyTeller runs in 6 seconds.
I was suspicious of Edge on that new machine because it sometimes struggled to display a web page, showing an error for a few seconds before loading the page. Since some software will use components of Edge, I thought it might have been the culprit and it was. What is killing me is that this fix on my home machine causes PowerAutomate to work with the same performance on both my home machine and my work machine and I did not uninstall Edge form my work machine. I will do it anyway and test again. These machines are sharing the same screens and are connected to the same router.

View solution in original post

14 REPLIES 14
miketran13
Solution Specialist
Solution Specialist

Hi,

 

While debugging, you can change the delay time to speed up the execution. 

speed.png

And when running without debugging, you have no worries about the speed.

runn.png

 

Thanks and hope it can help you. 

Mike

---------------------------------

Did I answer your question? Please consider to Mark my post as a solution! to guide others

I was referring to the runtime from the console, not the debugging.
I guess that my question is still open. Now I think this PAF works by triggering something in the cloud.
Could that be why it takes so long to start the execution? network latency, firewall rules, filters, round trips etc.
Guys, I thought Automate Desktop was Desktop, not cloud. On Desktop their would be NO latency.
Thoughts?

fraenK
Memorable Member
Memorable Member

PAD always creates a flow session in the cloud environment before starting the flow to record the run details.

 

Are you using the latest version of PAD? https://powerusers.microsoft.com/t5/Power-Automate-Desktop/New-releases-Power-Automate-Desktop-clien...

 

Multiple seconds delay between actions sounds strange. Does the task manager show signs of high load? Or are there any other (security/display) tools running so PAD needs more time to catch the right window?

I have tested on work and home machine with an internet connection around 400/25Mbps. I do not see much load at the time I run these flows. I created a few flows, they are all slow, some are VERY slow. I installed the desktop version a couple days ago. V2.5.39.21056

fraenK
Memorable Member
Memorable Member

I installed the version from the link, no change, still slower than what it should be.
I can do it manually in 9 seconds
Flow takes 35 seconds to complete
This was when using the window key and type the app name.
I changed to flow to use the Run Application action. This revised flow runs in 16 seconds, almost double than doing it manually. Still too slow.

fraenK
Memorable Member
Memorable Member

Maybe it's the application you're trying to automate?

Try to run and enter something in this AnyTellerDemo (just search for the name, had to remove the link, otherwise post was marked as spam and removed)

 

You can copy/paste the following code, just change the app path and add the selectors (3 fields + button):

 

DateTime.Local DateTimeFormat: DateTime.DateTimeFormat.DateAndTime CurrentDateTime=> CurrentDateTime
System.RunApplicationAndWaitToLoad ApplicationPath: $'''C:\\Users\\user\\Downloads\\AnyTellerDemo.exe''' WindowStyle: System.ProcessWindowStyle.Normal Timeout: 0 ProcessId=> AppProcessId WindowHandle=> WindowHandle
@@timestamp: '2021-03-19T17:53:14.8734109Z'
UIAutomation.FormFilling.PopulateTextField TextField: appmask['Window \'frmAnyTeller\'']['Edit \'WindowsForms10.EDIT.app.0.378734a\''] Text: '123'
@@timestamp: '2021-03-19T17:53:17.7583136Z'
UIAutomation.FormFilling.PopulateTextField TextField: appmask['Window \'frmAnyTeller\'']['Edit \'WindowsForms10.EDIT.app.0.378734a\' 2'] Text: '456'
@@timestamp: '2021-03-19T17:53:20.6835115Z'
UIAutomation.FormFilling.PopulateTextField TextField: appmask['Window \'frmAnyTeller\'']['Edit \'WindowsForms10.EDIT.app.0.378734a\' 3'] Text: '678'
@@timestamp: '2021-03-19T17:53:23.2672391Z'
UIAutomation.FormFilling.PressButton Button: appmask['Window \'frmAnyTeller\'']['Button \'Accept\'']
DateTime.Local DateTimeFormat: DateTime.DateTimeFormat.DateAndTime CurrentDateTime=> CurrentDateTime2
DateTime.Subtract FromDate: CurrentDateTime2 SubstractDate: CurrentDateTime TimeUnit: DateTime.DifferenceTimeUnit.Seconds TimeDifference=> TimeDifference
Display.ShowMessage Message: TimeDifference Icon: Display.Icon.None Buttons: Display.Buttons.OK DefaultButton: Display.DefaultButton.Button1 IsTopMost: False ButtonPressed=> ButtonPressed

 

Execution takes 3,9 seconds on my machine from the console

That is 9.4 seconds on my machine.
Teller opens quickly, then there is a few seconds delay before the first text is entered.

fraenK
Memorable Member
Memorable Member

Strange! Tried it on another machine and it runs in 4 seconds.

What CPU does your machine have?

pcand1001
Helper I
Helper I

I need to test from somewhere else than from my home network. I did run the same AnyTeller test on my home machine and it took 127 seconds!
The laptop is a XPS i7 10875H @ 2.3GHz SSD System 32GB RAM
The home machine is a Vostro i7 10700 @ 2.9GHz, SSD system 16GB RAM
Other test I could do, reboot Router, Disable anti-virus and firewall and see it that helps. Then Run the test on remote machine which is at work, then try on another older XPS laptop and work laptop as well on Wifi using my mobile phone as a hotspot?

pcand1001
Helper I
Helper I

I tried on a 3 years old machine at home and there the test runs in 5 seconds.

fraenK
Memorable Member
Memorable Member

So it must be a software issue, a common software on the other machines. Anti-virus/security or something from Dell, or driver or a multi-screen thing.

pcand1001
Helper I
Helper I

Unbelievable but I could resolve the issue by uninstalling the Win10 build-in Edge browser using command line and reinstalling it from the regular installer. Now AnnyTeller runs in 6 seconds.
I was suspicious of Edge on that new machine because it sometimes struggled to display a web page, showing an error for a few seconds before loading the page. Since some software will use components of Edge, I thought it might have been the culprit and it was. What is killing me is that this fix on my home machine causes PowerAutomate to work with the same performance on both my home machine and my work machine and I did not uninstall Edge form my work machine. I will do it anyway and test again. These machines are sharing the same screens and are connected to the same router.

please ignore

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

May UG Leader Call Carousel 768x460.png

June User Group Leader Call

Join us on June 28 for our monthly User Group leader call!

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 Designer Feedback_carousel.jpg

Help make Flow Design easier

Are you new to designing flows? What is your biggest struggle with Power Automate Designer? Help us make it more user friendly!

Top Solution Authors
Top Kudoed Authors
Users online (4,392)