These are chat archives for Nethereum/Nethereum

10th
Oct 2018
Yuu0704
@Yuu0704
Oct 10 2018 00:41
@juanfranblanco
var ecKey = Nethereum.Signer.EthECKey.GenerateKey(); var privateKey = ecKey.GetPrivateKeyAsBytes().ToHex();
var account = new Account(privateKey);
var address = account.Address;
Am I done?
You can make a wallet with this code
also have you checked the windows, avalonia, xamarin.fomrs (android, ios, uwp) samples?
@Ilchuk-Mihail that is a too big range you are mainly asking geth to check the whole blokchain
that is why
if you are monitoring only a contract yeah..
i have done 1000 in the past, but check yourself if nothing is returned go to 100 it is fast enough to catch up
@TarrahArshad you don't have enough Ether to send that transaction
Yuu0704
@Yuu0704
Oct 10 2018 06:03
@juanfranblanco
Thank you.
I was able to confirm payment to my Wallet.
Juan Blanco
@juanfranblanco
Oct 10 2018 06:04
awesome :D
Yuu0704
@Yuu0704
Oct 10 2018 06:08
@juanfranblanco
It is a question. Remittance from Wallet, if the transaction is put on pending, will remittances after that work normally?
Juan Blanco
@juanfranblanco
Oct 10 2018 06:47
transactions need to be mined
hence they appear as pending in etherscan
Yuu0704
@Yuu0704
Oct 10 2018 06:50
Do I need to use MineAndGetReceiptAsync?
Juan Blanco
@juanfranblanco
Oct 10 2018 06:51
if you look at the code i sent
you have TransferEtherAndWaitForReceiptAsync
if you are in the mainchain
that will take normally 12 seconds
so you will just use the Transfer and get the transaction hash
then you can poll in the background to get a confirmation it has been included in the chain
Yuu0704
@Yuu0704
Oct 10 2018 06:55
Thank you
I will try again.
Yuu0704
@Yuu0704
Oct 10 2018 07:41
I do not understand.
The way to obtain ABI and ByteCode for creating TransactionHash is
Michael Ilchuk
@Ilchuk-Mihail
Oct 10 2018 08:58
@juanfranblanco So you recomend use this way - periodically check , and change block range ?
Or exist better way to monitor own addresses for tokens transfer?
Juan Blanco
@juanfranblanco
Oct 10 2018 09:27
if you are just interested in a specific contract yeah
Michael Ilchuk
@Ilchuk-Mihail
Oct 10 2018 09:29
for now 1 contract
for futer more contarcts/tokens
1 event - transfer
@juanfranblanco It's like exchange
Juan Blanco
@juanfranblanco
Oct 10 2018 10:06
if you are only interested in 1 event check the workbook for events
there is an example there to catch all contracts
for an event type ie Transfer
Yuu0704
@Yuu0704
Oct 10 2018 10:46
I do not understand.
How to start mining with Xamarin.Forms.
turtlewen
@turtlewen
Oct 10 2018 10:55
hi may i know , if i already start mining ethereum private blockchain at window powershell , do i still need to put mining instruction in my web page using nethereum??
Juan Blanco
@juanfranblanco
Oct 10 2018 10:56
no
you don't
you can use one of the preconfigured testchains here
which start mining inmediatly https://github.com/Nethereum/TestChains
also they are PoA (geth and parity) so they are much faster
turtlewen
@turtlewen
Oct 10 2018 10:58
i ady create the private blockchain on my laptop localhost 8545 so can i use that one instead of test chain??
image.png
another problem is in my c# asp.net, i cannot get any result may i know any wrong of it?? because i want to try submit the set function of system request but on my window power shell it doesnot have any mining for new transaction
turtlewen
@turtlewen
Oct 10 2018 11:42
my smart contract function have few parameter, so what i should i use for nethereum to pass multiple parameter, is it CallDeserializingToObjectAsync??
Michael Ilchuk
@Ilchuk-Mihail
Oct 10 2018 12:18
@juanfranblanco Maybe it's old code - > var transferEventHandlerAnyContract = web3.Eth.GetEvent<TransferEventDTO>();
I dont see this method , only if I have contract i can GetEvent
Also, you recomend get all Transfer events from all contract and then filter by addresses and contract
?
addresses -> thousands
contract/token -> for now 1 , in future more
turtlewen
@turtlewen
Oct 10 2018 12:27
my problem solved.
turtlewen
@turtlewen
Oct 10 2018 17:34

@juanfranblanco

function getSystemRequest (string systemID)view public returns (string,string,string,string,string){

    newSystemRequestData storage s = systemRequest[systemID];

    return (s.systemID, s.requesterName,s.requestDescription,s.requestDate,s.requestTime);
}

my smart contract function, may i know which nethereum method i should use for to get back the value that return by that function??

currently i using var result = getFunction.CallDeserializingToObjectAsync<newSystemRequestData>(systemID);

but it is not working