web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Failed Launch Browser ...
Power Automate
Unanswered

Failed Launch Browser in Task Scheduler

(0) ShareShare
ReportReport
Posted on by 22

Hi there

i have a created a flow that launch a browser which is working fine

 

but if i set up a task scheduler and right click run, it fail

 

here is a screenshot of the error

 

s3135977_0-1688945149403.png

 

my current  setup, i TeamViewer into that computer to setup that flow, so its dedicate machine to run this 

 

I have the same question (0)
  • Agnius Bartninkas Profile Picture
    Most Valuable Professional on at

    Do you have a paid license of Power Automate that includes desktop flows? Running a flow via Task Scheduler requires a paid license.

    -------------------------------------------------------------------------
    If I have answered your question, please mark it as the preferred solution.
    If you like my response, please give it a Thumbs Up.

    If you are interested in Power Automate, you might want to follow me on LinkedIn at https://www.linkedin.com/in/agnius-bartninkas/

     

  • s3135977 Profile Picture
    22 on at

    Hi thank you for your reply

     

    I have an e3 license with a trail activated PAD license on the account, initially when i try to create a short cut for the flow, it ask if i want to trial premium, which i accepted

     

    i think its working cause when i put a steps in the flow to empty a folder that works, but when it get to launch a browser it error our from the screenshot you seen

  • Agnius Bartninkas Profile Picture
    Most Valuable Professional on at

    I haven't personally had a case like this. Your error is not very descriptive, as it simply says it failed, but does not actually contain any details. Would be great if you could add a Get last error action on error and log the message somewhere. Or at the very least, look at the Windows Event Viewer and see if there are any errors in the Application logs that would correspond to the flow failing.

     

    What I would suggest is to avoid using the Launch new Chrome (or any browser) action for actually launching the browser. The action depends heavily on the extension loading in time. It is quite frequent that the browser window is launched, but the extension lags behind and thus PAD assumes the action failed. This is a frequent issue.

     

    I would thus suggest using the Run application action to launch the browser and then use the Launch new Chrome action to attach to it. This is a much more stable approach and I've been using it for years.

     

    Here's what it would normally look like:

    AgniusBartninka_0-1688968272815.png

     

    This flow uses the Run application action to launch the Chrome app, passing in a default web page (in this case Google) as the parameter, waits for the window to appear (using Google as part of the window name, so it also waits for the page to load) and then attaches to it. This works all the time without the inconsistencies of the Launch new Chrome action.

     

    You can also copy and paste the following code into your PAD designer to get the same set of actions:

    SET URL TO $'''{SomeURL}'''
    System.RunApplication.RunApplication ApplicationPath: $'''chrome''' CommandLineArguments: $'''www.google.com''' WorkingDirectory: '' WindowStyle: System.ProcessWindowStyle.Maximized ProcessId=> AppProcessId
    WAIT (UIAutomation.WaitForWindow.ToOpenByTitleClass Title: $'''Google*''' Class: $'''Chrome_WidgetWin_1''' FocusWindow: True) FOR 30
    WebAutomation.LaunchChrome.AttachToChromeByTitle TabTitle: $'''Google''' AttachTimeout: 5 BrowserInstance=> BrowserMain
    ON ERROR REPEAT 5 TIMES WAIT 3
    END
    WebAutomation.GoToWebPage.GoToWebPageCloseDialog BrowserInstance: BrowserMain Url: URL

     

    Note that {SomeURL} in the snippet should be replaced with the actual URL to navigate to.

     

    It can easily be modified to use a different browser, too, by adjusting the application to be launch and the browser to be attached to.

    -------------------------------------------------------------------------
    If I have answered your question, please mark it as the preferred solution.
    If you like my response, please give it a Thumbs Up.

    If you are interested in Power Automate, you might want to follow me on LinkedIn at https://www.linkedin.com/in/agnius-bartninkas/

     

  • s3135977 Profile Picture
    22 on at

    HI thank you for your reply again,

     

    so copying your flow it failed at "Wait for Windows" even though its working if i manually run it through the shortcut

     

    but watching and reading up i notice people

    have "Run only when user is logged in"  selected where as in my task scheduler i have it run whether user is logged on or not

    s3135977_0-1688974575042.png

     

    opinion?

  • Agnius Bartninkas Profile Picture
    Most Valuable Professional on at

    Are you trying to run it when the user is logged out? If that is the case, then obviously any UI actions will fail. They can only run when the user is logged in.

    -------------------------------------------------------------------------
    If I have answered your question, please mark it as the preferred solution.
    If you like my response, please give it a Thumbs Up.

    If you are interested in Power Automate, you might want to follow me on LinkedIn at https://www.linkedin.com/in/agnius-bartninkas/

  • MarcoSchade Profile Picture
    30 on at

    I have the exact same issue. 

    Have you figured out how to get it to work yet? 

  • Drunk_Sailor Profile Picture
    5 on at

    Thank you Agnius. Your suggestion fixed my issue. The issue was the same. In testing or from the Power Automate menu i could run the flow. But when I scheduled it, it would not launch the browser.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 503 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 321 Moderator

#3
abm abm Profile Picture

abm abm 237 Most Valuable Professional

Last 30 days Overall leaderboard