All Questions
13 questions
0
votes
2
answers
57
views
contract.events
I am listening on an event that's happening on smart contract.
event UpdatedMaxNumber(address indexed player, uint maxNumber, uint256 timestamp);
My original code works fine and updates the new number ...
0
votes
2
answers
451
views
How to monitor events on an Solidity Smart Contract using hardhat and ethers?
I'd like to monitor events happening on-chain on a specific Smart Contract. I'd like to know every time a Transfer event happens. I tried to write a code with hardhat, but no events if being logged. ...
1
vote
1
answer
731
views
Filtering event always returns topics
I have an event in my contract:
event CreatedUnfinishedRandomSVG(uint256 indexed tokenId, address nftOwner, uint256[] randomWords);
In my JS script, I am trying to run some code only if the event that ...
1
vote
0
answers
377
views
How to pass Multiple Values in a Solidity Event
I am emitting within a function the following in a solidity smart contract.
emit Transfer(address(0), to, tokenId)
In my front-end JavaScript code, I am reading the values as follows:
let transfer = ...
2
votes
0
answers
296
views
How to watch/wait for events in JavaScript + Truffle?
I'm learning to develop Oracles, and, like all of us, I've encountered a dated article. After fixing all the Solidity changes (version, adding emit to fire an event, changing constructor function to ...
0
votes
1
answer
44
views
Array lenght and data miss match while storing data of events
Can someone help me in finding what is wrong here a why the length of task info is 0 even the taskInfo has some data. I'm using events to fill the taskinfo array.
I'm stuck at this place for almost 2 ...
0
votes
1
answer
401
views
Emited Solidity Events not being watched at frontend truffle contract instance
So, I have been reading through A LOT of pages about events in Solidity and how to interact with them on frontend but I am still pretty new to this and it seems like there have been multiple changes, ...
1
vote
2
answers
377
views
Events loading too slow
I have a dapp running on rinkeby at the moment, you can try it now on cryptogol.io, but I am facing a problem when reading events from the Blockchain. For example, yesterday I make the events happens, ...
1
vote
1
answer
1k
views
Show an event with nodejs
in my Smart Contract I have a function such that it fires an event at the end of its code.
function sendTran(arguments) public {
*code*
emit Event(argument 1,argument 3,argument 3,...
5
votes
2
answers
6k
views
How to convert Hexadecimal values into readable format?
I'm using etherscan API to fetch the event logs:
http://api-ropsten.etherscan.io/api?module=logs&action=getLogs&fromBlock=3147081&toBlock=latest&address=...
0
votes
2
answers
2k
views
Watch multiple contracts/events?
Is there a way to watch events from multiple contracts with just one watch-statement (something like [contract1.event, contract2.event, ...].watchAll() ) in Javascript?
Code is just for illustration ...
3
votes
1
answer
1k
views
Solidity print multiple data
I understood that print is not possible on Solidity, is recommended to use event and events can be read by using .watch. In order for an event to appear it has to be mined first.
What if I have a ...
3
votes
2
answers
563
views
Events dont fire when called too quickly
I have a very simple solidity function that just calls an event:
function sendMessage(int id, string title, string message){
Message(id, method, parameters);
}
When I call it using ...