I started learning ethereum and web3js and noticed some functions on Web3js are asynchronous. What i want to achieve is get the account balance of a wallet and use the data for something else. My code below  function getAccountBalance2(address){...
I have an issue with transactions on my local ethereum network - at some point, transaction hangs & spends a lot of ETH from my account.     Here's a sample code:  async function send(toAccount, weiVal) {   let account = await w3.getDefAccoun...
compile.js :  const path = require('path'); const solc = require('solc'); const fs = require('fs-extra');  const buildPath = path.resolve(__dirname, 'build'); fs.removeSync(buildPath);  const campaignPath = path.resolv...
currently i'm working on a ethereum dapp(voting), in my smart contract i have a function to fetch candidate list of type bytes32[] , on the java script side i'm not getting the values instead 0x only  How to parse the value , below is the cod...
Problem  I would like to have a website that updates live the user's wealth from a private Ethereum blockchain.   Current Solution (broken)  I opened a websocket to a private ethereum blockchain that is mining, I would like to update my coinbase...
I am simply trying to return the Balance value of an ethereum account using the web3 api, I would like to get that value in the $scope so I could use it in my html. Unfortunately I always get a value is undefined. I suspect it is coming from the fact...
Sorry if it is duplicated question. What does "_" operator make?  This code is from Ethereum contract manual: https://ethereum.org/token#deploying  contract owned {     address public owner;      function owned() {         owner = msg.sender;...
I'm trying to import the Ethereum web3.js library into a React Native project.  I've followed the React Linking Libraries instructions, installing the web3.js package and linking it with the commands:  $ npm install web3 --save $ react-native...
Context: I want to use blockies to render an identicon on the page, i get the defaultAccount from web3, for this, the user has to be logged on to metamask with a selected address from his wallet.   The problem: the web app seems to not detect the web...
I am writing test cases for my contract and have to delay the assertion check because it is time sensitive. getCompletedCampaigns() will have the address of the Campaign whose deadline has passed.  it("Time sensitive check", async () => {...

Tags

Recent Questions

Top Questions

Home Tags Terms of Service Privacy Policy DMCA Contact Us

©2020 All rights reserved.