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 / powershell script fire...
Power Automate
Unanswered

powershell script fire and forget

(0) ShareShare
ReportReport
Posted on by 2

I am trying to create a flow where for each subfolder in a specific folder a powershell command is executed (it opens the folder in a specific program, eg 7-zip). But every time the powershell command is executed the flow is stuck untill i close the 7zip windows. I want the flow to continue and open all the subfolders in 7zip even if I haven't finished and closed the first window

I have the same question (0)
  • MichaelAnnis Profile Picture
    5,727 Moderator on at

    I open 7zip files through PAD via command line.  Copy and paste the following into a PAD subflow.

     

    Cmd.Open Directory: $'''C:\\Program Files\\7-Zip''' Session=> CmdSession
    Cmd.Write Session: CmdSession Command: $'''7z.exe x \"C:\\stmt\\010SC-CBT WG2 -%RME_yyyyDASHmm% Statements and Confirms.7z\" -aoa -oC:\\stmt''' SendEnter: True
    Cmd.WaitForText Session: CmdSession Text: $'''Everything is Ok''' IsRegEx: False IgnoreCase: True Timeout: 0
    Cmd.Close Session: CmdSession

     

    Should look like this:

    MichaelAnnis_0-1639521830358.png

     

    Then you just have to edit your filename and path, and you can repeat as needed.

  • jasonpap Profile Picture
    2 on at

    thanks for your answer Michael, but that does not really answer my question. 

    7-zip is only part of the folder manipulation I want to do, so there is no way I can avoid running some powershell commands. 

    My issue is that I want the flow to continue after executing the powershell command, even if the program that is opened is still open. If I have 7 subfolders, I want the flow to run and open 7 different sessions. Right now it opens 1, and the flow continues when I close the 1st and so on

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 276 Super User 2026 Season 1

#2
11manish Profile Picture

11manish 169

#3
Haque Profile Picture

Haque 154

Last 30 days Overall leaderboard