This question already has an answer here:
I'm trying to do my first basic smart contract, following this popular HelloWorld tutorial.
However whenever I get to the part where I run a function in the truffle console, it is always telling me ".function_name is not a function".
For example, calling the default truffle MetaCoin getBalance function :
truffle(development)> MetaCoin.deployed().getBalance( web3.eth.accounts ) TypeError: MetaCoin.deployed(...).getBalance is not a function
Am I calling the function incorrectly?
How should I be calling the
.getBalance function in the MetaCoin example?