Relative Content

Tag Archive for arraysstringpowershell

How does a string unexpectedly become an array?

In one of my script I have the following problem: assigning to a string variable the result of a function makes the string an array. Example: $x=”” function findX{parm([string]prmx) … some code here $result=”abcd” } … $x= findX “xy” but if I look at it it’s $x=1 abcd and $x.Count is 2 I’ve made several […]