| external help file | Microsoft.PowerShell.Utility-help.xml |
|---|---|
| Locale | en-US |
| Module Name | Microsoft.PowerShell.Utility |
| ms.date | 01/24/2024 |
| online version | https://learn.microsoft.com/powershell/module/microsoft.powershell.utility/new-guid?view=powershell-5.1&WT.mc_id=ps-gethelp |
| schema | 2.0.0 |
| title | New-Guid |
Creates a GUID.
New-Guid [<CommonParameters>]
The New-Guid cmdlet creates a random globally unique identifier (GUID). If you need a unique ID in
a script, you can create a GUID, as needed.
New-GuidThis command creates a random GUID. Alternatively, you could store the output of this cmdlet in a variable to use elsewhere in a script.
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.
This cmdlet returns a GUID.
The cmdlet creates a Version 4 Universally Unique Identifier (UUID). For more information, see System.Guid.NewGuid.