ThePowerShellGuy.com

Did you do your PowerShelling today ?
Welcome to ThePowerShellGuy.com Sign in | Join | Help
in Search

Browse by Tags

All Tags » Hex » PowerShell
  • PowerShell : to Hex and back

    from an IRC question : [string]::join('',([byte[]]([regex]::matches(''1A3761592352350C7A5F20172F1E1A190E2B017313371312141A1539'','\w{2}') |% {''0x$_''}) |% {$_.tostring('x')})) 1a376159235235c7a5f20172f1e1a19e2b17313371312141a1539 Ok, maybe more useful on 2 lines ;-)  Enjoy, Greetings /\/\o\/\/
    Posted to The PowerShell Guy (Weblog) by MoW on May 2, 2007
  • Hey PowerShell Guy ! what is the Hex value of Chocolate ?

    Didn't you always' wanted to know this ?   This time not a Hey Scripting Guy ! translation, but from a NG post answer Translating colors to hex and back   (color asked was Red actually ;-) ) :PoSH> ''{0:x}'' -f ([drawing.Color]'Chocolate').ToArgb() ffd2691e ...
    Posted to The PowerShell Guy (Weblog) by admin on March 8, 2007
  • Scripting Games 2007 Beginner PowerShell Event 5

      I did not enter the beginners PowerShell Division, but did this 2 oneliners for Event 5: ABCs and 123s ( PS Answer: ABCs and 123s ) in the Beginner division: $r = $str.tochararray() | % {([int]$_).toString('x')} [String]::join('',[Char[]]($r |% {[int]''0x$_''})) So you get the Following output :  PoSH> $str = ''It ...
    Posted to The PowerShell Guy (Weblog) by admin on February 19, 2007
Powered by Community Server (Personal Edition), by Telligent Systems