Accessing an array inside a hashtable

Good morning reddit. i am stuck. I’m working on writing the log output of a script that starts virtual hosts and VMs from a report. This is the function that is writes each key:value of the hash:

Function Process- Output($server,$returnText,$returnCode,$output){ $returnInfo = $ReturnText,$returnCode if($output.ContainsKey($server)){ $output[$server] = $ReturnText,$returnInfo } else{ $output.add($server,$returnInfo) } return $output} 

If I just make it a single key:value (server:returnText for instance), there’s no issue.However, I’m struggling to figure out the correct syntax for getting inside an array in a hashtable.

submitted by /u/workerdrone66
[link] [comments]

Leave a Reply