powershell "if" needs to set two variables on match -


i need set 2 variables in script...

the first $vmcluster - what's proper syntax set variable if "if" matches?

if ($vmname -like "loupr*") {$vmcluster = "production"} 

it's script-block.... use line, or seperate ; .

if ($vmname -like "loupr*") {      $vmcluster = "production"     $secondvar = "secondvalue"     } 

or

if ($vmname -like "loupr*") { $vmcluster = "production"; $secondvar = "secondvalue" } 

Comments

Popular posts from this blog

SPSS keyboard combination alters encoding -

Socket.connect doesn't throw exception in Android -

iphone - How do I keep MDScrollView from truncating my row headers and making my cells look bad? -