These are chat archives for Nethereum/Nethereum

7th
Jan 2019
Cryt1c
@Cryt1c
Jan 07 16:39
Hi, I am back. Happy new year! :D
Is it possible when polling events from a contract to get the timestamp when the event was actually triggered? i think it would be enough to get the block which contains the transaction which triggered the event to have its timestamp. Is there a good way to do this?
Juan Blanco
@juanfranblanco
Jan 07 16:57
Happy New year!!
@Cryt1c you should be able to get the whole Log with the decoded event
that includes the block number
Cryt1c
@Cryt1c
Jan 07 17:01
ah yes found it. is there also a way to get the actual timestamp from the blocknumber?
The filter log has the block number and when querying a block you get the
timestamp
Cryt1c
@Cryt1c
Jan 07 17:06
thanks! what's the best way to query for a specific block?
Juan Blanco
@juanfranblanco
Jan 07 17:08
if not interested in the transactions just use this
or if you are
Cryt1c
@Cryt1c
Jan 07 17:10
perfect. will try to implement it using the first method. thanks a lot for the information.