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 / Calling Power Automate...
Power Automate
Unanswered

Calling Power Automate for Desktop from VBA

(0) ShareShare
ReportReport
Posted on by 7

Hello!

 

I have a spreadsheet calculator which requires data from a specific system. I'm trying to automate the scraping of the data to input into the calculator using a mix of VBA and Power Automate for Desktop for the job.

 

My ultimate aim is that the user will input a reference number into an Excel spreadsheet, click the macro button which will trigger the correct calculator to open. Once open, it will then call the web scrape Power Automate for Desktop flow to gather the data, write this back to the calculator, calculate and save the output somewhere for the user to pick up.

 

All of the individual steps have been done (opening the correct calculator based on the reference number, the flow which scrapes the data, saving of the output, etc), but I cant seem to figure out how I can get VBA (which is in the Desktop app of Excel, not online version) to call the Flow written in Power Automate for Desktop. Is this even possible?

 

Worth adding that I have the premium version of Power Automate for Desktop and that this is my first experience with power Automate for Desktop, so by no means am I anything more than a beginner!

 

Thanks in advance if anyone has the answer to this!

I have the same question (0)
  • Kaif_Siddique Profile Picture
    2,108 Super User 2024 Season 1 on at

    Hi @AR16985421543 

     

    Run macros on an Excel workbook:

    Kaif_Siddique_1-1675795785589.png

     

    To run the macro, deploy the Run Excel macro action and populate its name in the Macro field.

    Kaif_Siddique_2-1675795858982.png

     

    Refer the below link for reference:

    https://learn.microsoft.com/en-us/power-automate/desktop-flows/how-to/run-macros-excel

     

    Let me know if any queries.

     

    If I have answered your question, please mark my post as Solved.
    If you like my response, please give it a Thumbs Up.

     

    Regards

    Kaif

  • AR16985421543 Profile Picture
    7 on at

    Thanks Kaif.

     

    Sorry if I wasnt clearer in my original request, I am able to run macros from Power Automate just fine.

     

    What I am trying to do is invoke a flow from VBA as opposed to the other way around. So ultimately I want the VBA macro to call a flow I've designed in Power Automate for Desktop. Is there a way of doing this?

     

    Thanks

    Andrew

  • Verified answer
    momlo Profile Picture
    1,527 Super User 2024 Season 1 on at

    Hi @AR16985421543 

    If you have premium, you can:

    - create desktop shortcut and use it to trigger the flow or

    - copy the values from the desktop shortcut and trigger the app driectly or

    - use URL  to trigger the flow or

    - create power automate flow that accepts api and then executes the attended desktop flow, and then call the cloud flow from vba, but this will work only for machine set up for this particular pad action in power automate flow

     

    So I would use URL as simplest and cleanest:

    https://learn.microsoft.com/en-us/power-automate/desktop-flows/run-desktop-flows-url-shortcuts?source=recommendations

     

  • AR16985421543 Profile Picture
    7 on at

    That's great - thanks so much! 😊

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 522 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 364 Moderator

#3
abm abm Profile Picture

abm abm 243 Most Valuable Professional

Last 30 days Overall leaderboard