I wanted to create a script to verify/update various DNS and NTP settings for my entire collection of VMhosts across several datacenters and clusters. So I was experimenting with Get-VMHostNetwork and Set-VMHostNetwork.
I was frustrated with the rather terse help text for these cmdlets. The help for the Set-VMHostNetwork cmdlet specifies that the values for -DNSaddress and for -SearchDomain should be strings. The help text fails to mention what form the parameter should be if providing multiple values. Based on my experiments If it's given as an inline text string it can be given as a comma separated list. However, if providing the same as a $variable, the variable must be of type array with one value per element. It would be extremely helpful if this is spelled out in the help text and in the examples.
Is my interpretation correct? I'm using PowerCLI 5.1