Avatar of Kelly Garcia
Kelly Garcia
Flag for United Kingdom of Great Britain and Northern Ireland asked on

PowerShell Out-gridview

Hi,

I have the out-gridview in my powershell script, is there a way i could force the grid to allow only one selection?

  $SelectedStorage = ($StorageAccounts | Out-GridView -Title 'Select Azure Storage' -PassThru)

Open in new window


also is there a way i can set a default selection?

thank you in advance,
Kelly
Powershell

Avatar of undefined
Last Comment
Sam Jacobs

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
oBdA

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
Sam Jacobs

Add -OutputMode Single to the cmdlet.
I started with Experts Exchange in 2004 and it's been a mainstay of my professional computing life since. It helped me launch a career as a programmer / Oracle data analyst
William Peck