コード例 #1
0
ファイル: MainForm.cs プロジェクト: simplitech/neo-gui
        private void voteToolStripMenuItem_Click(object sender, EventArgs e)
        {
            WalletAccount account = (WalletAccount)listView1.SelectedItems[0].Tag;

            using (VotingDialog dialog = new VotingDialog(account.ScriptHash))
            {
                if (dialog.ShowDialog() != DialogResult.OK)
                {
                    return;
                }
                Helper.SignAndShowInformation(dialog.GetTransaction());
            }
        }
コード例 #2
0
        private void voteToolStripMenuItem_Click(object sender, EventArgs e)
        {
            InvocationTransaction tx;
            Contract contract = (Contract)listView1.SelectedItems[0].Tag;

            using (VotingDialog dialog = new VotingDialog(contract.ScriptHash))
            {
                if (dialog.ShowDialog() != DialogResult.OK)
                {
                    return;
                }
                tx = dialog.GetTransaction();
            }
            using (InvokeContractDialog dialog = new InvokeContractDialog(tx))
            {
                if (dialog.ShowDialog() != DialogResult.OK)
                {
                    return;
                }
                tx = dialog.GetTransaction();
            }
            Helper.SignAndShowInformation(tx);
        }