0

For example, I set a tParam as

value: web3.utils.toWei('0.01','ether'),

...

const txHash = await window.ethereum.request({
      method: "eth_sendTransaction",
      params: [tParam],
    });

It should show 0.01 ETH in Metamask, but showing 1.xx.

Where can be the problem point?

2 Answers 2

0

Found out that the value should be string hex.

0

If the transaction parameter value with Wei is different from Metamask, then the transaction will not be processed. You will need to double check the parameter value with Wei and make sure it is the same as the one you entered in Metamask.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.