I am using a smart contract which creates a token instance in its constructor:
contract Exemple{
Token public myToken
function Exemple(){
myToken=Token(this);
}
}
How can i access this token instance from outside of the contract (using truffle console)? For instance to make a command such as: myToken.approve(address,value, {from: other_account})
Hope my question makes sense. Just a beginner here…
Best Answer
You can get contract instance as below:
Using Web3:
From Truffle console: