예제 #1
0
        private void decrypt_text_button_Click(object sender, EventArgs e)
        {
            plain_text_box.Clear();

            Cypher cypher = new Cypher();
            plain_text_box.Text = cypher.decrypt_string(cypher_text_box.Text, password_cypher_box.Text);
        }
예제 #2
0
        private void decrypt_line_button_Click(object sender, EventArgs e)
        {
            plain_text_box.Clear();

            Cypher cypher = new Cypher();
            int counter = 0;
            string[] plainstring = new string[cypher_text_box.Lines.Length];

            foreach (string line in cypher_text_box.Lines)
            {
                if (line.Length > 0)
                    plainstring[counter] = cypher.decrypt_string(line, password_cypher_box.Text);
                else
                    plainstring[counter] = "";

                counter++;
            }

            plain_text_box.Lines = plainstring;
        }