function BkupHist
($computername){
.
.
$SqlAdapter.SelectCommand = $SqlCmd
$DataSet = New-Object System.Data.DataSet
$SqlAdapter.Fill($DataSet)
$SqlConnection.Close()
Clear
return $DataSet
}
$test = BkupHist
if i type $dataset.Tables[0] within the function I have data but I get the
following error if I do the same to $test.Tables[0]
Cannot index into a null array.