title: managed identity for this assignment does not have the appropriate permissions to remediate these resources. Edit Assignment page and re-save it
body: <p>I have a requirement of creating policy assignment from policy initiative and do remediation. I can create assignment using the below command.</p>
  <pre><code>$newRgAssignment = New-AzPolicyAssignment -Name $assigName -PolicySetDefinition $policySet -PolicyParameterObject $Params -AssignIdentity -Location 'westus' -scope $rgscope -DisplayName $assigName
  </code></pre>
  <p>In this I can create assignment successfully. while trying to remediation manually in I can see the below error message in azure portal .</p>
  <pre><code>The managed identity for this assignment does not have the appropriate permissions to remediate these resources. To add these permissions, go to the Edit Assignment page for this Policy and re-save it.
  </code></pre>
  <p>I tried creating a policy assignment by passing SystemAssigned identity type but ran into same problem.</p>
  <p>I have left with only one option that is UserAssigned identity type. To pass this parameter we need to get the assigned user identity . To get the user identity I used the below commands</p>
  <pre><code>Set-AzContext -Subscription 'XYZ-123-ABC'
  $UserAssignedIdentity = Get-AzUserAssignedIdentity
  </code></pre>
  <p>But no use.</p>
  <p>Can any one help me on this issue. Any help can be appriciated.
  Thank you.</p>