Skip to main content

Notifications

Community site session details

Community site session details

Session Id : Nt/9gUfw2FyFA0J6p2TieR
Power Automate - Power Automate Desktop
Answered

Seeking Free Alternatives for Automated PAD Workflow

Like (1) ShareShare
ReportReport
Posted on 5 Jul 2024 01:11:48 by 8

I understand that a premium license is required to enable automatic flow initiation for  PAD.

Does anyone have ideas on how to create a similar workflow with the following actions for free?

・ The flow should activate every Wednesday.
・ Take a screenshot from a specific site.
・ Place the screenshot in a specific Excel file at the following cells:
First in A1, then in D1, and thirdly in H1.

Additionally, I would like to know how to create a workflow that performs these tasks without the initial action.

 

Categories:
  • mathiaskjeldsen Profile Picture
    222 on 09 Jul 2024 at 19:11:25
    Re: Seeking Free Alternatives for Automated PAD Workflow

    Hey - as everybody else states here, this is a premium license action, so you would unfortunately need to cough up some money to get this sorted. For the request you need to get sorted, I just uploaded a video on my channel on how to handle that as I have to do a similar thing (take progress screenshots of KPIs from a dashboard - but the point is the same). It's a fairly easy operation. I normally set a variable to cover the date of the day its running, and then it's just launching a browser, going to a website, using the take screenshot action and saving it in a file using the variable as a prefix to save the file in yyyyMMdd_name arrangement. I'll link my profile below in case you need video to support.

     

     https://www.youtube.com/@matkjeldsen

  • NathanAlvares24 Profile Picture
    1,673 Super User 2025 Season 1 on 05 Jul 2024 at 05:08:56
    Re: Seeking Free Alternatives for Automated PAD Workflow

    Hi @Korokd !

     

    I can give you a flow using PAD but to do automatic flow runs definitely requires a premium license.

     

    But I did see some info somewhere but haven't tried it out. Here are some links:

    Run Flow From Command Prompt or Windows Task Scheduler | Power Automate Gallery

    (given by @VJR )

     

    YouTube links:

    How to schedule in Power Automate Desktop WITHOUT Power Automate Cloud or Premium license) 

    One STEP hack to schedule in Power Automate Desktop WITHOUT Power Automate Cloud or Premium license) 

     

    The full flow:

    NathanAlvares24_0-1720154152793.png

     

    I have used Python and PowerShell to accomplish this.

     

    Make sure to have this installed into your system using cmd (Administrator):

    pip install pyautogui openpyxl

     

    Python script (save it as script.py in some folder):

    import pyautogui
    import openpyxl
    from openpyxl.drawing.image import Image
    from openpyxl.utils import get_column_letter
    import time
    from datetime import datetime
    import os
    
    # Function to take a screenshot
    def take_screenshot(filename):
     screenshot = pyautogui.screenshot()
     screenshot.save(filename)
    
    # Function to resize and insert image into Excel
    def insert_resized_image_into_excel(image_path, excel_path, cell, width=None, height=None):
     if not os.path.exists(excel_path):
     # Create a new workbook if the file does not exist
     wb = openpyxl.Workbook()
     wb.save(excel_path)
     else:
     # Load existing workbook
     wb = openpyxl.load_workbook(excel_path)
    
     ws = wb.active
     img = Image(image_path)
    
     # Resize image if width or height is provided
     if width and height:
     img.width = width
     img.height = height
    
     ws.add_image(img, cell)
    
     # Adjust column width to fit the resized image
     column_letter = cell[0]
     ws.column_dimensions[column_letter].width = img.width / 7 # Adjust as needed
    
     wb.save(excel_path)
    
    # Get the current date and format it
    current_date = datetime.now().strftime('%A_%b_%d_%Y')
    
    # Create the filenames
    image_filename = f"C:/Users/Nathan/Desktop/TestingSaveScreenshotToExcel/screenshot_{current_date}.png"
    excel_filename = f"ExcelFile_{current_date}.xlsx"
    excel_path = f"C:/Users/Nathan/Desktop/TestingSaveScreenshotToExcel/{excel_filename}"
    
    # Take screenshot
    take_screenshot(image_filename)
    
    # Insert resized image into Excel at specified cell and adjust column width
    insert_resized_image_into_excel(image_filename, excel_path, 'A1', width=300, height=200) # Adjust width and height as needed
    insert_resized_image_into_excel(image_filename, excel_path, 'D1', width=300, height=200) # Adjust width and height as needed
    insert_resized_image_into_excel(image_filename, excel_path, 'H1', width=300, height=200) # Adjust width and height as needed
    
    # Optional: Add delay to ensure the tasks are performed sequentially
    time.sleep(5)

     

    PowerShell script (have to put this in PAD using the Pre-built action):

    NathanAlvares24_5-1720156118522.png

    # Run the Python script
    Start-Process -FilePath '%pythonPath%' -ArgumentList '%scriptPath%' -NoNewWindow -Wait

     

    Output:-

    Before:

    NathanAlvares24_1-1720155818254.png

     

    After:

    NathanAlvares24_2-1720155833227.png

     

    Image:

    NathanAlvares24_3-1720155847603.png

     

    Excel file:

    NathanAlvares24_4-1720155874732.png

     

     

    And to run this every Wednesday, you would need premium using the Windows Task Scheduler. More info here in the link on how to set it up:

    https://www.youtube.com/watch?v=pFZSajbQsxc by the infamous, Anders Jensen.

     

    Code (just copy paste into your flow):

    SET pythonPath TO $'''C:\\Python312\\python.exe'''
    SET scriptPath TO $'''C:\\Users\\Nathan\\Desktop\\TestingSaveScreenshotToExcel\\script.py'''
    WebAutomation.LaunchChrome.LaunchChrome Url: $'''https://www.activision.com/?utm_source=404&utm_medium=redirect&utm_campaign=122222''' WindowState: WebAutomation.BrowserWindowState.Maximized ClearCache: False ClearCookies: False WaitForPageToLoadTimeout: 60 Timeout: 60 PiPUserDataFolderMode: WebAutomation.PiPUserDataFolderModeEnum.AutomaticProfile BrowserInstance=> Browser
    @@copilotGeneratedAction: 'False'
    Scripting.RunPowershellScript.RunPowershellScript Script: $'''# Run the Python script
    Start-Process -FilePath \'%pythonPath%\' -ArgumentList \'%scriptPath%\' -NoNewWindow -Wait''' ScriptOutput=> PowershellOutput ScriptError=> ScriptError
    WebAutomation.CloseWebBrowser BrowserInstance: Browser

     

    I hope this helps.

  • Verified answer
    VishnuReddy1997 Profile Picture
    2,324 Super User 2025 Season 1 on 05 Jul 2024 at 04:52:02
    Re: Seeking Free Alternatives for Automated PAD Workflow

    Hi @Korokd ,

     

    Unfortunately, triggering PAD Workflows automatically on a specific schedule (like every Wednesday) requires a premium license.

     

    To create your flow in PAD. I have created  a sample but you need to change it according to your requirement.

     

    Here are the steps:


    1.Take a screenshot from a specific site:
    Add a Launch new Chrome action and enter the URL of the site you want to take a screenshot from.
    Add a Web page screenshot action. This will take a screenshot of the currently active web page in Chrome.
    2.Save the screenshot:
    Add a Save image action and specify the file path where you want to save the screenshot.
    3.Open the Excel file and insert the screenshot:
    Add an Excel Launch and attach action and specify the path of your Excel file.
    Add an Excel Set cell picture action and specify the cell (A1, D1, or H1) and the file path of the screenshot.
    Repeat steps 3-5 for each cell you want to insert a screenshot into.
    4.Close the Excel file and the browser:
    Add an Excel Close action to close the Excel file.
    Add a Close web browser action to close the browser.

     

     

    VishnuReddy1997_0-1720154629774.png

     

    (Note:- if you got your solution you can mark as solution and gives kudos)


    Thanks & Regards

    Vishnu Reddy

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

Understanding Microsoft Agents - Introductory Session

Confused about how agents work across the Microsoft ecosystem? Register today!

Warren Belz – Community Spotlight

We are honored to recognize Warren Belz as our May 2025 Community…

Congratulations to the April Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,743 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 66,089 Most Valuable Professional

Leaderboard