[#wallet-CalculateMaximumSignedTxSize-08]
= xref:wallet.adoc[wallet]::CalculateMaximumSignedTxSize
:relfileprefix: ../
:mrdocs:

`CalculateMaximumSignedTxSize` overloads

== Synopses

Declared in `&lt;wallet&sol;spend&period;h&gt;`

Calculate the size of the transaction, looking up previous outputs from the wallet&period;


[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
&lsqb;&lsqb;requires&lowbar;capability(0x7f94fde58080)&rsqb;&rsqb;
xref:wallet/TxSize.adoc[TxSize]
xref:wallet/CalculateMaximumSignedTxSize-0d.adoc[CalculateMaximumSignedTxSize](
    xref:CTransaction.adoc[CTransaction] const& tx,
    xref:wallet/CWallet.adoc[CWallet] const* wallet,
    xref:wallet/CCoinControl.adoc[CCoinControl] const* coin&lowbar;control = nullptr);
----

[.small]#xref:wallet/CalculateMaximumSignedTxSize-0d.adoc[_» more&period;&period;&period;_]#

Calculate the size of the transaction using CoinControl to determine whether to expect signature grinding when calculating the size of the input spend&period;


[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
xref:wallet/TxSize.adoc[TxSize]
xref:wallet/CalculateMaximumSignedTxSize-00.adoc[CalculateMaximumSignedTxSize](
    xref:CTransaction.adoc[CTransaction] const& tx,
    xref:wallet/CWallet.adoc[CWallet] const* wallet,
    std::vector&lt;CTxOut&gt; const& txouts,
    xref:wallet/CCoinControl.adoc[CCoinControl] const* coin&lowbar;control = nullptr);
----

[.small]#xref:wallet/CalculateMaximumSignedTxSize-00.adoc[_» more&period;&period;&period;_]#

== Return Value

The estimated virtual size and weight of the signed transaction&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *tx*
| The transaction whose signed size is estimated&period;
| *wallet*
| The wallet that owns the inputs and provides signing information&period;
| *coin&lowbar;control*
| Coin control settings used to decide whether to expect signature grinding&period;
| *txouts*
| The previous outputs spent by the transaction&apos;s inputs&period;
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
