Nethereum异常:“在JSON中找不到必需的属性'代码'。”

时间:2018-04-27 19:47:09

标签: ethereum solidity web3

我正在试图与Nethereum签订合同。我知道合同有效,因为我可以用Web3.JS调用它。但是每当我尝试用Nethereum调用它时,我都会传入以下参数。

        conn = new Web3(url);
        contract = conn.Eth.GetContract(abi, address);
        Function castVote = contract.GetFunction("castVote");
        var result = await castVote.SendTransactionAsync(account, null, null, account, candidate);

我没有太多解释就得到以下异常......

Nethereum.JsonRpc.Client.RpcClientUnknownException: Error occurred when trying to send rpc requests(s) ---> Newtonsoft.Json.JsonSerializationException: Required property 'code' not found in JSON. Path 'error', line 1, position 6776.

这会导致什么?我在网上找不到任何东西。

0 个答案:

没有答案