I am fairly new to Solidity and slowly starting to grasp its ecosystem :-) I have a question about using delegateCall: How do I ensure that I call exactly the contract I want to call?

Let's assume I have contract A (in file A.sol) and contract B (in file B.sol). I deploy both contracts. In A, I would like to use delegateCall to use a function in B. Is this possible without knowing the address of B? If so how do I ensure that I do call my contract B and not any other contract with the exact same name?

I hope I state the problem with the correct terms.

1 Answer 1


Whenever you want to interact with a contract be it between multiple on-chain contracts or a javascript client and an on-chain contract you do need the address of the contract you're trying to interact with.

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.