10
Answers

Deserialize text file into datagrid

mike Delvotti

mike Delvotti

10y
929
1

Guys, is it possible to Deserialize a binary text file and read it into a datagridview?

My below code does a rough job of trying to display it onto a message box but doesn't format it correctly

Ideally it would be nice to read the contents into a datagridview, is that possible?

            FileStream readStream;
            string msg = null;
            try
            {
               
                readStream = new FileStream("c:\\DB.dat", FileMode.Open);
                BinaryReader readBinary = new BinaryReader(readStream);
                msg = readBinary.ReadString();
                MessageBox.Show(msg);
                readStream.Close();
            }


Answers (10)