Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- [System.Collections.ArrayList]$StringXML = & $MediaInfoBinary '--Output=XML' $Path
- try{[xml]$MediaInfo = $StringXML}
- catch [Exception]
- {
- $ExceptionSplit = $_.Exception.Message.Split(".")
- $LineSplit = (($ExceptionSplit[$ExceptionSplit.Length - 2]).Trim()).Split(",")
- $Line = (($LineSplit[0].Trim()).Split(" "))[1]
- $Line = $Line - 1
- $StringXML.Remove($StringXML[$Line])
- [xml]$MediaInfo = $StringXML
- }
Add Comment
Please, Sign In to add comment