Search found 4 matches

by andylyonette
Fri Jun 30, 2017 4:45 pm
Forum: PowerShell GUIs
Topic: Different script execution between GUI and Non-GUI
Replies: 17
Views: 5434

Re: Different script execution between GUI and Non-GUI

Thanks for looking into this further. SIgning into Azure works fine, it's the Get-AzureRmRoleAssignment cmdlet that's hanging it for me, I've attached the test project I created.

Thanks,
Andy
AzureTest.zip
(25.43 KiB) Downloaded 116 times
by andylyonette
Fri Jun 30, 2017 3:00 pm
Forum: PowerShell GUIs
Topic: Different script execution between GUI and Non-GUI
Replies: 17
Views: 5434

Re: Different script execution between GUI and Non-GUI

Target: Microsoft Windows 64 Bit
Script Engine: SAPIEN PowerShell V5 Host (Windows Forms)

Toggling STA on/off doesn't seem to make a difference.

Is there any way to find out for sure what the issue is rather than just assume it won't work?

Thanks,
Andy
by andylyonette
Fri Jun 30, 2017 1:41 pm
Forum: PowerShell GUIs
Topic: Different script execution between GUI and Non-GUI
Replies: 17
Views: 5434

Re: Different script execution between GUI and Non-GUI

I've created a new single-form project with 1 button and am running only these 3 lines: $AzureAccount = Login-AzureRmAccount $AzureSignInName = $AzureAccount.Context.Account.Id Get-AzureRmRoleAssignment -SignInName $AzureSignInName It hangs on the Get-AzureRmRoleAssigment but the exact same code wor...
by andylyonette
Fri Jun 30, 2017 9:51 am
Forum: PowerShell GUIs
Topic: Different script execution between GUI and Non-GUI
Replies: 17
Views: 5434

Re: Different script execution between GUI and Non-GUI

I'm seeing the same issue with Get-AzureRmRoleAssignment - just locked up the app. If I run it in debug mode I can see it gets stuck straight away: DEBUG: 17:44:38 - GetAzureRoleAssignmentCommand begin processing with ParameterSet 'ScopeWithSignInNameParameterSet'. DEBUG: 17:44:38 - using account id...