Hi, I deploy a test contract here, https://apothem.blocksscan.io/address/xdc014A18E0631C8126450d8D9D9e59F4D23A424bF0#readContract
this contract is working on eth, bsc, avax, polygon and harmony chain, not sure why it is not working on xdc chain.
Developers Forum for XinFin XDC Network
Hi, I deploy a test contract here, https://apothem.blocksscan.io/address/xdc014A18E0631C8126450d8D9D9e59F4D23A424bF0#readContract
this contract is working on eth, bsc, avax, polygon and harmony chain, not sure why it is not working on xdc chain.
For further actions, you may consider blocking this person and/or reporting abuse
AnilChinchawale -
Rohit Dubey -
Tyler Carter -
Galaxy -
Discussion (15)
The format of ["1000000000000000000","1000000000000000000"] should be [1000000000000000000,1000000000000000000]. Does your contract on XDC chain has enough XDC coin to pay out?
I deployed your contract to
xdc2e78f2ACd8A5CA6dD5B0B8Fb502E3ea160E54C00
. And I can execute function disperseXdc with parameters["0x48800ede4Be8DabAFDCD4bdb05b099dB2b236846","0x796c0E3A2e78a699502a35a65f9734a355210036"]
and[1000000000000000000,1000000000000000000]
successfully. The transaction is explorer.apothem.network/tx/0x4ce6... .how did you make it work? I tried it on my end it still fails, I'm using remix.xinfin.network
I use remix deploy contract, and call function disperseXdc.
I'm using remix.xinfin.network or should I use remix.ethereum.org/?
I use
https://remix.ethereum.org/
with RPChttps://erpc.apothem.network/
Hi have you tried sending some XDC instead of 0? still getting tmap error even after changing the format
I add a function
receive() external payable {}
in contractHummingbotMinerPayouts
. And deployed it atxdc2e78f2ACd8A5CA6dD5B0B8Fb502E3ea160E54C00
. Then transfer 100 XDC to this contract. At last call functiondisperseXdc
with parameters["0x48800ede4Be8DabAFDCD4bdb05b099dB2b236846","0x796c0E3A2e78a699502a35a65f9734a355210036"]
and[1000000000000000000,1000000000000000000]
successfully. You can check balance ofxdc48800ede4Be8DabAFDCD4bdb05b099dB2b236846
andxdc796c0E3A2e78a699502a35a65f9734a355210036
. Please check transaction explorer.apothem.network/txs/0x4ce... also.thanks will try this
We hope that the above issue is resolved, if the issue is still persist then please let us know about it so that the team can resolve it on priority. It will be grateful to get an update within 72 hours or else it will be considered resolved.
Should add function receive() into contract, so contract can receive ethers, then contract can transfer ethers to other accounts.
it working now.. thanks!! BTW do you think is it possible to use the XDC from the contract sender instead of transferring the tokens to contract?
This depends your business requirements. Maybe WXDC is more convenient than XDC.
Hello,
Can you share exact error here with step to reproduce it ?
explorer.apothem.network/address/x...
using the write Contract
DisperseXdc
inputs:
["0x48800ede4Be8DabAFDCD4bdb05b099dB2b236846","0x796c0E3A2e78a699502a35a65f9734a355210036"]
["1000000000000000000","1000000000000000000"]
TypeError: t.map is not a function
at c.formatParam (9a2ee76.js:2:904212)
at 9a2ee76.js:2:902499
at Array.map ()
at c.encodeParameters (9a2ee76.js:2:902411)
at 9a2ee76.js:2:893256
at Array.map ()
at m._encodeMethodABI (9a2ee76.js:2:893230)
at m._processExecuteArguments (9a2ee76.js:2:897736)
at m._executeMethod (9a2ee76.js:2:898168)
at 932080a.js:1:17610
getting this error on console
tried running the function on remix, it only displayed
transact to HummingbotMinerPayouts.disperseXdc pending ...
tried using yodaplus safe the transaction failed:
explorer.apothem.network/txs/0x700...
Hello @dendenski
Since we haven’t received any response from your side , we are closing the issue as it appears to be resolved. If you still have the issue, please feel free to reopen it.
Thank you!