![](/img/trans.png)
[英]The term 'Get-AzureRmDataFactoryV2' is not recognized as the name of a cmdlet
[英]Get-MgApplication is not recognized as the name of a cmdlet - Power Shell
我正在嘗試運行 Microsoft 提供的 Contoso 貨幣化代碼示例 Web 應用程序,作為從付費加載項轉向 SaaS 產品的起點。 我被困在我打算更新 Azure Active Directory 應用程序的最后。 我收到這個錯誤
Get-MgApplication :術語“Get-MgApplication”不被識別為 cmdlet、函數、腳本文件或可運行程序的名稱。 檢查名稱的拼寫,或者如果包含路徑,請驗證路徑是否正確,然后重試。 + $webApp = Get-MgApplication -top 400|Where-Object {$_.DisplayName -eq ...+ CategoryInfo : ObjectNotFound: (Get-MgApplication:String) [], CommandNotFoundException +fullyQualifiedErrorId : CommandNotFoundException
這是引用“Get-MgApplication”的代碼。
$webApp = Get-MgApplication -top 400|Where-Object {$_.DisplayName -eq $webAppDisplayName}
$webAppSiteName = $armConfigJson.parameters.webAppSiteName.value
$redirectUris = "https://$webAppSiteName.azurewebsites.net/signin-oidc","https://$webAppSiteName.azurewebsites.net/"
Update-MgApplication -ApplicationId $webApp.Id -WebRedirectUris $redirectUris
我在網上查了一下,沒有找到這個模塊是否可以導入和加載。 我還使用命令 get-Module 檢查是否在 power shell 模塊文件夾中並且可能拼寫錯誤,但也不在那里。 任何幫助都感激不盡。
您需要安裝 Microsoft.Graph.Beta cmdlet - https://github.com/microsoftgraph/msgraph-sdk-powershell/tree/master
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.