Last modified: 2024-09-14
Ledger.GetTransaction Method
Gets transaction by transaction hash.
Namespace: Neo.SmartContract.Framework.Native
Assembly: Neo.SmartContract.Framework
Syntax
public static extern Transaction GetTransaction(UInt256 hash);
Parameter:
-
hash: The hash of the queried transaction
Example
public class Contract1 : SmartContract.Framework.SmartContract
{
public static void Test(UInt256 hash)
{
var tx = Ledger.GetTransaction(hash);
}
}