BitcoinLib.BlockchainAPI.BlockExplorer.TxConfirmation C# (CSharp) Method

TxConfirmation() public static method

public static TxConfirmation ( string TxHash ) : TxStatus
TxHash string
return TxStatus
        public static TxStatus TxConfirmation(string TxHash)
        {
            if (string.IsNullOrWhiteSpace(TxHash.Trim()))
                throw new ArgumentException("Undefined or Null argument are not valid!", nameof(TxHash));

            var BApiEx = new Info.Blockchain.API.BlockExplorer.BlockExplorer();
            var tx = BApiEx.GetTransaction(TxHash);
            var LBtx = BApiEx.GetLatestBlock();

            var TxConf = new TxStatus((LBtx?.Height - tx?.BlockHeight + 1), tx.DoubleSpend);
            return TxConf;
        }
BlockExplorer