An Azure service that is used to automate, configure, and install updates across hybrid environments.
I was able to run changing ,net target framework to 4.8. it was 4.6 before.
Thank you
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Hello
Using System.Management.Automation.Runspaces
Calling azure powershell module using c# application , connect-azaccount throws this exception.
System.Management.Automation.CmdletInvocationException: Method 'SendRequest' in type 'Microsoft.Azure.ServiceManagement.Common.Models.RecordingTracingInterceptor'
from assembly 'Microsoft.Azure.PowerShell.Common, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' does not have an implementation. --->
System.TypeLoadException: Method 'SendRequest' in type 'Microsoft.Azure.ServiceManagement.Common.Models.RecordingTracingInterceptor' from assembly
'Microsoft.Azure.PowerShell.Common, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' does not have an implementation.
at Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet.SetupDebuggingTraces()
at Microsoft.Azure.Commands.ResourceManager.Common.AzureRMCmdlet.SetupDebuggingTraces()
at Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet.BeginProcessing()
at Microsoft.Azure.Commands.Profile.ConnectAzureRmAccountCommand.BeginProcessing()
at System.Management.Automation.Cmdlet.DoBeginProcessing()
at System.Management.Automation.CommandProcessorBase.DoBegin()
--- End of inner exception stack trace ---
at System.Management.Automation.Runspaces.PipelineBase.Invoke(IEnumerable input)
An Azure service that is used to automate, configure, and install updates across hybrid environments.
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
I was able to run changing ,net target framework to 4.8. it was 4.6 before.
Thank you
Hello @Sai Pranav - Thanks for reaching out.
It appears you are calling it from C#.
Connect-AzAccount
is a PowerShell cmdlet (not an executable) and has to be run from within a PowerShell session, either interactively or from within a PowerShell script or by upgrading your version.
Hope that helps.
Please feel free to "Accept as Answer" if it helped answer your query.