Users browsing this thread: 3 Guest(s)
hex editing multiple files
#7
(06-03-2015, 02:18 AM)puggsoy Wrote:
Code:
Get-ChildItem "C:\MyFiles" -Filter *.XA | `
Foreach-Object{
   $bytes = [System.IO.File]::ReadAllBytes($_.FullName);
   $bytes[2] = 0x4A;
   
   [System.IO.File]::WriteAllBytes("C:\MyFiles\" + $_.BaseName + ".XA", $bytes);
}

Thank you! This works beautifully. Good Job.
A small bug though: the .txt in the first line has to be .XA Wink
[Image: stitch_hi_by_guy_who_does_art-d7hridu.jpg]
Reply
Thanked by: puggsoy


Messages In This Thread
hex editing multiple files - by SuperFlomm - 06-02-2015, 12:36 PM
RE: hex editing multiple files - by Petie - 06-02-2015, 01:54 PM
RE: hex editing multiple files - by SuperFlomm - 06-02-2015, 02:29 PM
RE: hex editing multiple files - by Petie - 06-02-2015, 09:40 PM
RE: hex editing multiple files - by SuperFlomm - 06-02-2015, 11:19 PM
RE: hex editing multiple files - by puggsoy - 06-03-2015, 02:18 AM
RE: hex editing multiple files - by SuperFlomm - 06-03-2015, 12:25 PM
RE: hex editing multiple files - by puggsoy - 06-03-2015, 09:34 PM
RE: hex editing multiple files - by Petie - 06-03-2015, 02:30 PM

Forum Jump: