This seems very easy to do however for the life of me I cant get TRUE when loading a script.
My script is located at
/home/ubuntu/scripts/ethersc.js
in my ubuntu machine. The content of the file is:
function checkAllBalances() {
var i =0;
eth.accounts.forEach(function(e){
console.log(" eth.accounts["+i+"]: " + e + " \tbalance: " + web3.fromWei(eth.getBalance(e), "ether") + " ether");
i++;
})
};
I'm running the command:
loadScript('/home/ubuntu/scripts/ethersc.js')
and all i get is
false
Any hints would be appreciated
0 ·
Comments