well i got it working somehow.have attached it.can it be made more elegant than my code?I have made a similar program for serial port instead of reading from file it reads from serial port.What if the serial port stops sending data,i want a GUI error message and control back.the other file has also been attached(serial one which requires more help).Also i need to create within this gui another entry which sends data the user enters as and when he wants to,but the problem is while loop takes contol.<br>