Hex String to byte array conversion
OK...so what I'm really trying to do is use the Assembly.Load function to dynamically load an assembly, that is in the GAC (and not part of my local project). My research indicates that to do this, I need to give the Load function an AssemblyName object that has the .Name, .Version, and public key specified. So for a test, I tried to load System assembly dynamically.
This is the info I came up with when I looked in the GAC:
Public key: b77a5c561934e089
Ok so the name and Version is no problem, but the AssemblyName.SetPublicKey function expects a Byte array as input.
So this is where I'm at, trying to figure out how to convert the string "b77a5c561934e089" into a suitable byte array. I have a feeling that somewhere in the framwork there exists a function that does all the work on this, but I can't seem to find it. Any help would be appreciated.