Questions tagged [web3j]
Lightweight Java and Android library for integration with Ethereum clients
327
questions
0
votes
0answers
208 views
web3.js-1.0.0 General Availability (GA) Date ?
When will web3js 1.0.0 be General Available? i.e., web3 GA date
0
votes
1answer
208 views
reject transaction in metamask from code after few minutes
Can anyone tell me if it is possible to reject transaction in metamask from javascript or java code after few minutes, if user didn't submit or reject it by himself?
The problem is that the user of ...
0
votes
1answer
472 views
Error while retrieving transaction count
I am trying to retrieve the total transaction count of an address using java, web3j and Infura as the Ethereum client. My code is as below:
EthGetTransactionCount txnCount = web3j....
0
votes
1answer
365 views
Getting exception when trying get balance using web3j
I use code above to get balance using web3j:
Web3j web3 = Web3j.build(new HttpService("https://ropsten.etherscan.io/address/0xAccountAddress"));
EthGetBalance ethGetBalance = null;
try {
...
0
votes
1answer
654 views
Web3j decode function from TransactionReceipt
I'm connecting to a testnet using a Geth node running version 1.8.8-stable,
and also I'm using the web3j lib version 3.4.0.
I deployed a Smart Contract and also used the web3j wrapper tools to ...
0
votes
1answer
331 views
Not getting any results from Web3j querying of ERC20 token's balanceOf() function
I am trying to use Web3j to query the balanceOf() function of a standard ERC20 token as shown in the code below:
try {
String encodedFunction = FunctionEncoder.encode(function);
...
0
votes
1answer
226 views
How can I show on web3j a list of all the instructors added on my blockchain?
I need to show on an html a list of all the instructors that are set up on the list
pragma solidity ^0.4.18;
contract Owned {
address owner;
function Owned() public {
owner = msg.sender;
}
...
0
votes
1answer
67 views
I am transfering ethereum but showing 0 value and the transaction is successful
I am using web3j method sendFunds to transfer ether deducting the fee the transaction successful but showing 0 value in etherscan
Here is the link
0
votes
1answer
314 views
Web3j send ether transaction pending forever
i'm trying to send ether to a smart contract with a specified amount of gas usage, the transaction sending works fine and it propagates to the network but remains pending forever not being executed as ...
0
votes
1answer
1k views
Generating a BIP-39 compatible Ethereum wallet results in IndexOutOfBoundsException?
Trying to configure android app to use a master seed phrase instead of individual private key generation.
Using the new(ish) generatebip39wallet results in an indexoutofboundsexception.
Offending ...
0
votes
1answer
475 views
How is it possible that Web3j is send Transaction over Infura.io?
Infura can't unlock Accounts over JSON RPC/web3.js
infura FAQ.
How is it possible that Web3j can send Transaction over Infura.io?
Web3js uses also JSON RPC to communicate with the Blockchain.
So ...
0
votes
1answer
734 views
Web3j - Transfer.sendFunds wait forever
After struggling with issue from Geth (then I decided to use Geth 1.8.2, magically it solve the problem).
I found 2 approaches to send ether :
The First approach are the codes following
...
0
votes
1answer
331 views
Interacting with the smart contract from Java application (We3j)
I have many questions about the workflow ( sequence ) of interacting with the smart contract from Java application, so I will first explain what I have done and then put my questions, and if something ...
0
votes
1answer
426 views
How to list all recipts in a block using web3js?
I'm trying to list all transactions and their receipts from given block. Transactions get be included in the result of GetBlockByNumber function but I have found no option to include receipts.
I can ...
0
votes
1answer
292 views
Correct way to easily call function with web3j from deployed contract
I am trying to call a function from a modified ERC20 contract and I can't manage to make it work. I am doing this with web3j from Android.
I can connect to Infura. The contract is already deployed on ...
0
votes
1answer
430 views
Not able to convert and access Tuples of bytes array and convert to string in Java using web3j
I am new to the development of smart contract using web3j. I am facing issue, while converting Bytes32[] returned from wrapper of contract(.sol) method to array.
I have contract as:
pragma solidity ...
0
votes
0answers
373 views
Why do I always get 'private key length is invalid' when launching testrpc from java with predefined accounts?
Im trying to deploy testrpc from java with two accounts starting with funds, and I keep getting an error saying "private key length is invalid" from testrpc. Below is my code:
private static final ...
0
votes
0answers
290 views
cannot deploy a contract with web3j
I am able to generate the contract just fine, and able to create a wallet, but when I try to deploy the contract on testrpc, I always get an exception saying I dont have enough funds. How can you ...
0
votes
0answers
256 views
Subscription stop after only a few blocks in Web3j
I am using the following code to catch and receive new transactions:
DefaultBlockParameter startingBlock = DefaultBlockParameter.valueOf(lastActionedBlockNumber.add(BigInteger.ONE));
...
0
votes
2answers
507 views
How to use balanceOf function with Web3j for an android app
I am trying to use the balanceOf function after the generation of our smart contract (pakoin) function wrappers in Java with Web3j. Despite trying different ways, I get plenty of errors and I don't ...
0
votes
2answers
2k views
Android webj3 “insufficient funds for gas * price + value” exception
I'm trying to send ether in my Android app between 2 addresses which were opened using Metamask.io
There is a balance of 2 ethers in "from" account.
Here the code
Web3j web3 = Web3jFactory....
0
votes
1answer
1k views
Unable to retrieve value from Web3j sendFunds Future
I have been trying to send funds from one ethereum account to another using web3j to test that it works on Android. I am using an Infura cloud instance.
First, it appears I need to send it async ...
0
votes
1answer
466 views
Getting exception with web3j new transaction listener code
I am using web3j to receive all new transactions as they are added to the blockchain. I am using private blockchain. Here is my code:
web3j.transactionObservable().subscribe(tx -> {
...
0
votes
2answers
308 views
Smart Contract with web3j - Stored SHA hash returned is not the same as input
I have a contract that stores sha-256 hashes of documents (stored as bytes32). I also have a method to retrieve a hash that is mapped to a unique id for the document. However, when I retrieve and ...
0
votes
2answers
431 views
Web3.eth.accounts[0] never updating
I'm trying to use Web3 to access the current account I have selected on Metamask by doing web3.eth.accounts[0] in order to display it on my UI (in VueJS). However web3.eth.accounts[0] always returns ...
0
votes
1answer
319 views
calling method using web3j returns null
while calling an contract method using web3j returns null.Deployed in Remix ,getting response and deployed in geth console ,got response.
-5
votes
1answer
150 views
Need help integrating ERC20 on Exchange [closed]
Pardon my ignorance, as I have very less knowledge of ERC20 and Ethereum.
I am part of an exchange development and we have successfully integrated coins but when it came to ERC20 tokens, we are ...