Need to do the Application Group Assignment for users via powershell

Balaji Ranganathan 6 Reputation points
2022-01-31T10:43:56.553+00:00

In AVD, Need to do the Application Group Assignment for users via PowerShell .?

I am not able find any PowerShell cmdlet for the same.

169780-image.png

Azure Virtual Desktop
Azure Virtual Desktop
A Microsoft desktop and app virtualization service that runs on Azure. Previously known as Windows Virtual Desktop.
1,385 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. srbhatta-MSFT 8,546 Reputation points Microsoft Employee
    2022-01-31T18:55:08.577+00:00

    Hi @Balaji Ranganathan ,
    Thank you for reaching out to Microsoft QnA.
    To assign a user to an Application Group via powershell, you can run the below Powershell cmdlet. I have tried it myself and it worked.

    New-AzRoleAssignment -SignInName <UPN> -RoleDefinitionName "Desktop Virtualization User" -ResourceName <ApplicationGroupName> -ResourceGroupName <ResourceGroupName> -ResourceType 'Microsoft.DesktopVirtualization/applicationGroups'  
    

    Please do not forget to 'Accept as Answer' if the information provided was helpful so that it can benefit others looking for help on similar topics.

    1 person found this answer helpful.
    0 comments No comments