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

Community site session details

Session Id : IMMCfAe88m9OxgPF3X8xrR
Power Automate - Power Automate Desktop
Suggested answer

how to use GUID function in PAD

Like (0) ShareShare
ReportReport
Posted on 8 Jul 2025 09:13:00 by 2
hello all,

as per my project requirements, i will have to use GUID function to generate a unique reference no for each API call which make to upload a file.

So, can any one please help me on how to use the same in PAD?

Thank you
Categories:
I have the same question (0)
  • Suggested answer
    Riyaz_riz11 Profile Picture
    3,622 Super User 2025 Season 2 on 09 Jul 2025 at 13:21:42
    how to use GUID function in PAD
    Hi,

    Solution 1: Use “Get Random Text” Action

    Power Automate Desktop has a built-in action called Get random text which you can use to create a GUID-like string.

    Steps:

     Add the Get random text action:

    • Random text length: 32 (or any length you prefer)

    • Text type: Alphanumeric

    • Output to variable: e.g., %UniqueID%

     (Optional) Format it to look like a GUID:

    • You can insert dashes to make it look like: 8-4-4-4-12

    • For example, you can:

      • Use Substring to split parts

      • Use Set Variable to concatenate with -

    Example:

    If you want something simpler, you can just keep it as a 32-character string, which is unique enough for file references.

    Solution 2: Use “Get Environment Variable” with a .NET GUID

    If you prefer a real GUID format, here’s a PowerShell trick that’s super reliable.

    Steps:

     Add Run PowerShell Script action:

    [guid]::NewGuid().ToString()
     

     Store the result in a variable, e.g., %UniqueID%

     This returns:

    7a8b9c12-3456-7890-abcd-ef1234567890
     
    If I have answered your question, please mark it as the preferred solution ✅ . If you like my response, please give it a Thumbs Up 👍.
    Regards,
    Riyaz

     
  • Suggested answer
    VishnuReddy1997 Profile Picture
    2,550 Super User 2025 Season 2 on 08 Jul 2025 at 09:35:17
    how to use GUID function in PAD
     
    Power Automate Desktop (PAD) does not have a built-in action called "Generate GUID". But you can generate GUID using Run Powershell script action as shown in below image
     
     
    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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Telen Wang – Community Spotlight

We are honored to recognize Telen Wang as our August 2025 Community…

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Tomac Profile Picture

Tomac 986 Moderator

#2
stampcoin Profile Picture

stampcoin 699 Super User 2025 Season 2

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 577 Super User 2025 Season 2

Loading complete