I think till now you understand what exactly I am asking for.
I have recognize the Problem and my problem is in below code
Qt Code:
  1. void ui_logging::Button_Clicked()
  2. {
  3.  
  4. QTextStream in(file); //My Problem is here on every click I am creating the object again and again
  5.  
  6. for( i = 0;i<10;i++)
  7. {
  8.  
  9. in>>str1;
  10. qDebug()<<str1;
  11.  
  12. }
  13. int n = in.pos();
  14.  
  15.  
  16. }
To copy to clipboard, switch view to plain text mode 
Do you have any solution for the above.