Exemple #1
0
        private void Button2_Click(object sender, EventArgs e)
        {
            string key      = MyPolibus.Normalize(txtKey2.Text);
            string text     = txtText2.Text.Replace(" ", string.Empty).ToLower();
            var    keyArray = MyPolibus.CreateMatrixWithKey(key);

            answer2.Text = MyPolibus.getDecodeText(text, keyArray);
        }
Exemple #2
0
        private void Button3_Click(object sender, EventArgs e)
        {
            string key        = MyPolibus.Normalize(txtKey1.Text);
            string text       = txtText1.Text.Replace(" ", string.Empty).ToLower();
            var    keyArray   = MyPolibus.CreateMatrixWithKey(key);
            var    indexArray = MyPolibus.CreateIndexArray(text, keyArray);

            answer1.Text = MyPolibus.getEncrypedText(indexArray, keyArray);
        }