0

enter image description here

tokenContractAddress is 0xc778417E063141139Fce010982780140Aa0cD5Ab on execution, returns

enter image description here

but balance of WETH in my wallet is 2 WETH as i can see. How is it possible?

enter image description here

2 Answers 2

2

It seems you are checking balance of contract in code , whereas in metamask , you are chcking balance of weth in the user address.

2
  • Got it right...
    – Haris
    Jun 3, 2022 at 7:10
  • How can I check WETH balance of user using etherjs? Jun 3, 2022 at 7:32
0

enter image description here

Thank you @Ashish. We need to use address of wallet instead of contract address

Your Answer

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

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