I have a text file. The text file contain of this
Name(0x0)/Class(0x17,0x0)/Format(0x0,0xFFFF,0x0)
I want to get this string only Format(0x0,0xFFFF,0x0)
I try to split it and get the array number. BUT THE PROBLEM is this format text file sometime change. This string Format(0x0,0xFFFF,0x0) NOT always in the last array, and the total of array sometime different as well. like this.
Name(0x0)/Class(0x17,0x0)/Class2(0000,0000)/Format(0x0,0xFFFF,0x0)
or
Name(0x0)/Class(0x17,0x0)/Format(0x0,0xFFFF,0x0)/Class2(0000,0000)
My expectation, I can get this string Format(0x0,0xFFFF,0x0) , wherever it's place.
Anyone can help me please. Thanks a lot.
$File = Get-Content .\PC.txt
$split = $File -split "/"
$found= $split[2]
$found
Select-String