0

For example if I want to warn my user that he make mistake in contract address.

Anton Pegov
  • 213
  • 2
  • 5
  • 1
    Though this doesn't help if there is a contract at the given address, but it's the wrong contract. – Richard Horrocks Apr 28 '18 at 17:43
  • Should this question be edited to focus on Richard's second comment? Otherwise this question is a duplicate of the other questions raised in the comments. – eth May 01 '18 at 07:42

1 Answers1

2

If you want to check whether an particular address contain some code just run below command from geth

web3.eth.getCode (addressstring). For more info https://googleweblight.com/i?u=https://web3js.readthedocs.io/en/1.0/web3-eth.html&hl=en-IN Or you can simply check on etherescan.io

rahul_eth
  • 556
  • 1
  • 4
  • 11