Questions tagged [send]
The send tag has no usage guidance.
15
questions
0
votes
0
answers
10
views
What does the Promievent .off() do?
The docs don't explain what it does, and i couldn't find a single thing anywhere.
My goal is to exit a contract.methods.function.send() call early after getting the transaction hash, without waiting ...
0
votes
0
answers
14
views
Force .send() to return early transaction hash instead of waiting for receipt
let txResult = await myContract.methods
.myContractFunction(addressInputParam, amountInputParam)
.send({ from: owner, gas: 200000 })
.on("transactionHash", function (hash) {
const ...
1
vote
1
answer
38
views
How to send ether to a contract (even if the contract doesn't implement receive or fallback functions)? [duplicate]
If the contract doesn't implement the receive or fallback function as payable, it can't receive funds?
0
votes
0
answers
28
views
crawling last transactions
I am making a program to monitor who is sending ether to my wallet.
I thought I could get the most recent blocks this way, but the repoFactory was empty.
What could be the problem?
i want to crawl ...
0
votes
1
answer
25
views
How to send from a contract to a personal wallet
// SPDX-License_Identifier: MIT
pragma solidity >=0.6.6 <0.9.0;
//2.56
//import "@chainlink/contracts/src/v0.8/interfaces/AggregatorV3Interface.sol";
import "hardhat/console.sol&...
0
votes
1
answer
30
views
Send Ether from SC to EAO
I came across many blogs saying the defacto standard to send ether from one contract to another and why one is better than the other. However, what is the best practice for sending ether from contract ...
1
vote
2
answers
977
views
How to send a value to smart contract function using meta mask and web3.js?
I tried to follow a tutorial https://livecodestream.dev/post/interacting-with-smart-contracts-from-web-apps/
I was able to retrieve the number via call function, but was not able to update the number ...
0
votes
2
answers
234
views
Transferring an NFT via MetaMask
Im onto developing my own NFT project.
Im developing with the Truffle Suite and Ganache.
I can mint the NFT to my address, but whats wondering me: I cant send the NFT because the "send" ...
0
votes
1
answer
19
views
Sending balance to contract fails
I'm playing ethernaut, the king of the hill level. I made a practice target contract and an attacking contract. I want to send value to the attacking contract (this works) then I want to send the ...
0
votes
1
answer
152
views
What is the "bytes memory" in (bool success, bytes memory) = some_address.call{value: some_amount}("")
I understand that the success tells if the receive/fallback methods returned successfully but what does the memory give?
0
votes
0
answers
556
views
How to send BNB (or other networks) with web3 on a dapp?
So, I tried the many examples found around but I never manage to get it working.
I have this snippet:
async function pay(cost) {
code = 0
message = "Please approve the tx"
...
0
votes
0
answers
99
views
Calling a non-payable function that mutates state? (web3)
With web3, you can call read-only functions using 'call()' (eg, balanceOf), and functions that mutate state with 'send({from: adr, value: 10})'
I'm able to call payable and non-payable functions fine, ...
0
votes
1
answer
762
views
Error calling web3.eth.Contract send() function gives error: Method not found
I just deployed a contract and wants to access it using web3 to read and write data.
I have web3 working, passed the contract Address and ABI and I can access the contract and Read Data using:
...
0
votes
1
answer
147
views
EVM:out of gas while executing send
I want to consider a scenario, lets suppose that a contract performs a transfer using send. At this point, out of gas occurs and send returns -1. Now the contract has no gas, and send does not revert,...
0
votes
1
answer
349
views
Error: Member "send" not found or not visible after argument-dependent lookup
I am trying to compile the following smart contract:
pragma solidity ^0.5.1;
contract Governmental{
uint constant TWELVE_HOURS = 12;
function lendGovernmentMoney ( address buddy ) public ...