[#DecodeHexTx] = DecodeHexTx :mrdocs: Decode a hex‐encoded serialized transaction. == Synopsis Declared in `<core_io.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- [[nodiscard]] bool DecodeHexTx( xref:CMutableTransaction.adoc[CMutableTransaction]& tx, std::string const& hex_tx, bool try_no_witness = false, bool try_witness = true); ---- == Return Value True if the transaction was decoded successfully. [NOTE] ==== The return value https://en.cppreference.com/cpp/language/attributes/nodiscard[should not be discarded^]. ==== == Parameters [cols="1,4"] |=== | Name| Description | *tx* | Transaction populated with the decoded data on success. | *hex_tx* | Hex string holding the serialized transaction. | *try_no_witness* | When true, attempt to parse the input as a non‐witness (legacy) transaction. | *try_witness* | When true, attempt to parse the input as a segwit (witness) transaction. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#