Skip to main content
edited tags
Link
Paul Razvan Berg
  • 18.7k
  • 6
  • 79
  • 148
added 4 characters in body; edited tags
Source Link
eth
  • 86.5k
  • 53
  • 287
  • 411

I want to know how to instantiate an existing contract deployed intoon the blockchain using its address. e.g:

contract A {
    funtcionfunction f1()
    {}
}

Deployed intoA is deployed on the blockchain, and in contract B I want to call the function f1() and get its return. e.g:

contract B {
    address contrac_A=0x123456;
    
    //call ff1 from A
}

How should I call it using the address of A?

I want to know how to instantiate an existing contract deployed into the blockchain using its address. e.g:

contract A {
    funtcion f1()
    {}
}

Deployed into the blockchain, and in contract B I want to call the function f1() and get its return. e.g:

contract B {
    address contrac_A=0x123456;
    
    //call f from A
}

How should I call it using the address of A?

I want to know how to instantiate an existing contract deployed on the blockchain using its address. e.g:

contract A {
    function f1()
    {}
}

A is deployed on the blockchain, and in contract B I want to call the function f1() and get its return. e.g:

contract B {
    address contrac_A=0x123456;
    
    //call f1 from A
}

How should I call it using the address of A?

calling fonction Calling function from deployed contract

Source Link
Sig Touri
  • 1.1k
  • 2
  • 14
  • 23
Loading