Ethereum: Error trying to send SepoliaETH between two remix accounts via smart contract with special conditions: Error reason –>undefined gas
I can walk you through the process of creating a smart contract in Remix that maps a payment transaction between two Sepolia ETH accounts in different Metamask wallets.
Prerequisites:
- You have Remix installed on your Ethereum blockchain.
- You have a Sepolia ETH wallet and a Metamask wallet configured in your MetaMask.
- You have a basic understanding of smart contract development in Remix.
Step 1: Create a new remix contract
// Map the payment transaction
_mappedTransactions[sender][amount] = recipient;
// Set the mapped payment transaction to the storage array
interface._mappedTransactions[sender][amount] = recipient;
}
// Function to retrieve a mapped payment transaction
function recall(uint64 amount) public {
// Check if there is a mapping for sender and value
require(_mappedTransactions[sender][amount] != address(0), "Mapping does not exist");
// Cancel the mapped payment transaction
delete _mappedTransactions[sender][amount];
}
}
Step 4: Compile and deploy the contract
Compile your Remix contract with the following command:
remix -p --interface PaymentTransactionInterface --contract SepoliaPaymentMap
Deploy your contract on the Ethereum blockchain.