public static dynamic ShowSellAccount() { SellAccount sellAccount = new SellAccount(); if (sellAccount.ShowDialog() == DialogResult.OK) { return(new { Fee = sellAccount.fee.Value, Price = sellAccount.accountPrice.Value, Seller = sellAccount.sellerAccount.Text }); } else { return(false); } }
private void sellAccount_ItemClick(object sender, ItemClickEventArgs e) { if (gridControl1.DefaultView.RowCount < 2) { return; } var account = (Account)accountBindingSource.Current; var accountKey = Keys.FirstOrDefault(p => p.PublicKey.X.SequenceEqual((byte[])account.AccountInfo.AccountKey.PublicKey.X) && p.PublicKey.Y.SequenceEqual((byte[])account.AccountInfo.AccountKey.PublicKey.Y) ); account.AccountInfo.AccountKey = accountKey; var a = SellAccount.ShowSellAccount(); if (a is bool) { return; } Node.Instance.SellAccount(account, a.Price, a.Fee, a.Seller, accountKey); }