This repository was archived by the owner on Jul 19, 2024. It is now read-only.
Description Hi,
I found an issue, the CreateAzureServicesScript.ps1 does not ran very well and gave me an error here like:
New-AzureRmADApplication : Cannot bind parameter 'Password'. Cannot convert the "Password.1%" value of type
"System.String" to type "System.Security.SecureString".
At line:1 char:142
... homePageURL1 -IdentifierUris $identifierURI1 -Password $passwordADApp
~~~~~~~~~~~~~~
+ CategoryInfo : InvalidArgument: (:) [New-AzureRmADApplication], ParameterBindingException
+ FullyQualifiedErrorId : CannotConvertArgumentNoMessage,Microsoft.Azure.Commands.ActiveDirectory.NewAzureADAppli
cationCommand
so I added
$securePASS = ConvertTo-SecureString -String $passwordADApp -AsPlainText -Force
before line :
$azureAdApplication1 = New-AzureRmADApplication -DisplayName $displayName1 -HomePage $homePageURL1 -IdentifierUris $identifierURI1 -Password $securePASS
note that I replaced -Password $passwordADApp to -Password $securePASS
My first time using power shell script so I don't know if it's a good solution
Reactions are currently unavailable
Hi,
I found an issue, the CreateAzureServicesScript.ps1 does not ran very well and gave me an error here like:
New-AzureRmADApplication : Cannot bind parameter 'Password'. Cannot convert the "Password.1%" value of type
"System.String" to type "System.Security.SecureString".
At line:1 char:142
... homePageURL1 -IdentifierUris $identifierURI1 -Password $passwordADApp
~~~~~~~~~~~~~~
+ CategoryInfo : InvalidArgument: (:) [New-AzureRmADApplication], ParameterBindingException
+ FullyQualifiedErrorId : CannotConvertArgumentNoMessage,Microsoft.Azure.Commands.ActiveDirectory.NewAzureADAppli
cationCommand
so I added
$securePASS = ConvertTo-SecureString -String $passwordADApp -AsPlainText -Forcebefore line :
$azureAdApplication1 = New-AzureRmADApplication -DisplayName $displayName1 -HomePage $homePageURL1 -IdentifierUris $identifierURI1 -Password $securePASSnote that I replaced
-Password $passwordADAppto-Password $securePASSMy first time using power shell script so I don't know if it's a good solution