Last active
October 2, 2023 10:59
-
-
Save svanas/504218bb76292334ea9086bc10d3a28a to your computer and use it in GitHub Desktop.
QuikNode
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var client: IWeb3 := TWeb3.Create('https://<your-node-name>.discover.quiknode.pro/<your-token>/'); | |
web3.eth.blockNumber(client, procedure(num: BigInteger; err: IError) | |
begin | |
TThread.Synchronize(nil, procedure | |
begin | |
if Assigned(err) then | |
MessageDlg(err.Message, TMsgDlgType.mtError, [TMsgDlgBtn.mbOK], 0) | |
else | |
MessageDlg(num.ToString, TMsgDlgType.mtInformation, [TMsgDlgBtn.mbOK], 0); | |
end); | |
end); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment