private void Button_Click(object sender, RoutedEventArgs e)
        {
            var str_pubkey = Dialog_Input.ShowDialog(this, "input publickey here.");

            if (string.IsNullOrEmpty(str_pubkey))
            {
                MessageBox.Show("error key set.");
                return;
            }
            var pubkey = ThinNeo.Helper.HexString2Bytes(str_pubkey);

            InitMainKey(pubkey);
        }
        public static string ShowDialog(Window owner, string label, string defvalue = "")
        {
            var d = new Dialog_Input();

            d.Owner     = owner;
            d.showtext  = label;
            d.text      = defvalue;
            d.tbox.Text = d.text;
            if (d.ShowDialog() == true)
            {
                return(d.text);
            }
            return(null);
        }