CapyKit/Documentation/Help/M_CapyKit_Helpers_KeyHelper_HexToBytes.md

46 lines
1.1 KiB
Markdown
Raw Normal View History

2025-02-14 04:52:55 -06:00
# HexToBytes Method
Converts a hex string back to a byte array.
## Definition
**Namespace:** <a href="N_CapyKit_Helpers.md">CapyKit.Helpers</a>
**Assembly:** CapyKit (in CapyKit.dll) Version: 1.0.4
**C#**
``` C#
private byte[] HexToBytes(
string hex
)
```
**F#**
``` F#
private member HexToBytes :
hex : string -> byte[]
```
#### Parameters
<dl><dt>  <a href="https://learn.microsoft.com/dotnet/api/system.string" target="_blank" rel="noopener noreferrer">String</a></dt><dd>The hexadecimal.</dd></dl>
#### Return Value
<a href="https://learn.microsoft.com/dotnet/api/system.byte" target="_blank" rel="noopener noreferrer">Byte</a>[]
A byte[].
## Exceptions
<table>
<tr>
<td><a href="https://learn.microsoft.com/dotnet/api/system.argumentexception" target="_blank" rel="noopener noreferrer">ArgumentException</a></td>
<td>Thrown when one or more arguments have unsupported or illegal values.</td></tr>
</table>
## See Also
#### Reference
<a href="T_CapyKit_Helpers_KeyHelper.md">KeyHelper Class</a>
<a href="N_CapyKit_Helpers.md">CapyKit.Helpers Namespace</a>