VB.NET files, listboxes and nested loops exercise.
The assignment is due on Wednesday, March 10th, 2004
Make sure that your raw text data file with whatever plaintext message is of interest to you is saved inside the Bin folder for your VB.NET project.
The raw text file above was named PlainText.txt. Here are the statements from my VB program that opened the file for input.
Dim fs As New FileStream("PlainText.txt", FileMode.Open, FileAccess.Read)
Dim strHobbits As New StreamReader(fs)
Make sure that you add the “Imports System.IO” statement at the top of your code window, so the FileStream and StreamReader class definitions are available.
Public Class frmEncrypt
The encryption method takes every 4th character of the plaintext from the 4th character, then every 4th character from the 3rd character, then every 4th character from the 2nd character, and finally every 4th character from the 1st character to create the encrypted by transposition (permutation) ciphertext of the original plaintext message.
1234567890UNI*Panther*Volleyball-rocks!! would be encrypted how?
I*Pa 48Naeoylc! 37UPhVelo! 260*t*lars 159Inrlb-k
lley but without the spaces shown above, it would be
Be sure to include one line of plaintext that makes it easy to see if your algorithm is correctly converting the plaintext to ciphertext.
12345678abcdABCDEFGHIJKLMNOPQRSTUVWXYZ makes it easy to
look for an spot
the 48dDH group, then the
37cCG group, followed by the
26bBF group, and ending with the
The name of my project is FlexGrid, so it is inside the FlexGrid folder that I find the bin folder and save a copy of the input data file (PlainText.txt) there.
My 030Net folder contains all VB.NET projects and work.