Click here to Skip to main content
15,867,686 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
I want to make a simple winform application that displays data stored as .txt (or maybe even as a database and display it as a graph)..
I want to make a C# winform application for this and have little prior development experience...
How can this be done.. ???
Posted
Comments
suramrit 14-Jan-13 7:42am    
The chart control.. :P
suramrit 14-Jan-13 7:43am    
But How can I get it to display data stored as a .txt file????

1 solution

use the stream reader class use this in formload

C#
try
            {
                StreamReader sr = new StreamReader(@"C:\Users\Vishnu\Desktop\hind.txt");

                    String txtread;
                    while ((txtread = sr.ReadToEnd()) != null)
                    {


                TextBox1.Text=txtread

                       
                    }
            }
            catch (Exception e)
            {
                

            }
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900