9 thoughts on “Jon Gurgul

  1. Thanks Jon
    really thanks for your help!
    I put the Output on a var, and with [1] i get only the first 3 values StartDate, EndDate, DaysLeft. Normaly i get this lines 3 times.

    But how can i cut/trim/edit the string in just the values?
    “@{StartDate=2011-02-10T00:00:00; EndDate=2014-02-11T00:00:00; DaysLeft=327}”
    thats the Output at the Moment.

    I want each value in an extra variable, is that possible?

    • A variable example looping thru each returned entry:

      Get-DellAssetInformation "6ZL84R1" | Select-Xml -XPath "/ArrayOfAsset/Asset/ns:Entitlements/ns:EntitlementData" -Namespace @{ns="http://support.dell.com/WebServices/"} | Select -expand node |%{
      $StartDateVariable = $_.StartDate;
      $EndDateVariable = $_.EndDate;
      $DaysLeftVariable = $_.DaysLeft;
      Write-Host "Started on "$StartDateVariable" End on "$EndDateVariable" "$DaysLeftVariable" day(s) remaining";
      }

Leave a Reply to Jon Gurgul Cancel reply

Your email address will not be published. Required fields are marked *