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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Running OCR when user ...
Power Automate
Answered

Running OCR when user is logged out

(0) ShareShare
ReportReport
Posted on by 10

I am trying to schedule a flow to run daily by using OCR to read current time on desktop and when matches with the set time it will trigger the remaining steps of the flow. While the flow runs successfully when I'm logged in, the OCR engine fails to boot when the laptop is locked. Is there any workaround to schedule a desktop flow or fire up the OCR engine in unattended mode? Thanks a lot!

 

P.S. since I'm using a company laptop, I can't schedule a basic task e.g. PING.exe to trigger the PAD flow when the laptop is locked without batch job right and the file is saved on a network drive (basic task can be executed using IP without issue though, again, when logged in). I also don't have a premium subscription of PA so I can't schedule a cloud flow to trigger the PAD flow.

 

Would greatly appreciate any help and wishing you all a happy holiday season!

I have the same question (0)
  • VJR Profile Picture
    7,635 on at

    Hi @cmdk_14 

     

    Just trying to understand a bit more.....

     

    ..using OCR to read current time on desktop..

     

    Is there any specific you are using OCR to read the current time?

    Are you unable to use the Get current date and time action for some reason?

     

    If you have a Virtual desktop machine and trying Image automation, you can still get the timezone of that machine using the above action.

  • cmdk_14 Profile Picture
    10 on at

    Thank you so much for the quick reply! I stumbled upon a Youtube video suggesting to use OCR to schedule flow but I agree that using 'get current date and time' would be a more sensible solution - currently I have the flow on a loop from 1 to 9999999999999999999999999999, is there a better way to run the flow as it is constantly going through all the steps to check if the current date/time matches with the one set in the "IF" condition?

     

    Thanks again!

  • VJR Profile Picture
    7,635 on at

    If the "If" condition is at the very beginning right after getting the current time then it won't have to go through all the steps.

    Can you share your Flow steps to suggest any discrepancies.

  • cmdk_14 Profile Picture
    10 on at

    Hi VJR, thanks again for replying, bear with me for the clumsy writing/ flow as I'm not a pro and am only working on this as part of the company's automation project:

     

    Screenshot 2022-12-22 094905.png

    Would it be possible to have PAD get the current date automatically to trigger the remaining steps without setting a loop?

     

    Extremely grateful for your help!

     

  • Verified answer
    VJR Profile Picture
    7,635 on at

    Hi @cmdk_14 

     

    A loop "like" structure will be needed because you want it to run it again and again on a daily basis.

    Step numbers 1 to 5 have to be run every single time.

     

    Note that these are not efficient ways.

     

    A premium subscription would have been best which allows scheduling of flows but I remember you do not have that.

     

    If you have to run only an Excel macro then you don't even need PAD.

    Just schedule the macro in the already available Windows Task Scheduler.

    How To Automatically Run Excel VBA Macros Daily (thespreadsheetguru.com)

     

  • cmdk_14 Profile Picture
    10 on at

    Hi VJR

    Apologies for the radio silence I hope you had a great time with your family on Christmas day!

     

    Running an xlsm file/vbs using task scheduler would definitely be much better than having PAD looping the whole flow every single second, I will have a chat with IT to see if it's possible to grant me appropriate right to enable tasks to run while logged out.

     

    Sorry for the delay and thank you so much again for your help! 

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 238 Super User 2026 Season 1

#2
11manish Profile Picture

11manish 225

#3
Haque Profile Picture

Haque 181

Last 30 days Overall leaderboard