Results 1 to 15 of 15

Thread: I don't get expected output in text browser

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jul 2010
    Posts
    71
    Thanked 8 Times in 8 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Red face I don't get expected output in text browser

    There is a problem in the program

    in mainwindow.h
    Qt Code:
    1. class input_events //: public MainWindow
    2. {
    3. typedef struct input ie;
    4.  
    5. public:
    6. ie *l;
    7. ~input_events();
    8. input_events();
    9. void add_ie(ie *p);
    10. };
    To copy to clipboard, switch view to plain text mode 

    in mainwindow.cpp

    Qt Code:
    1. struct input
    2. {
    3. int id;
    4. struct input * suiv;
    5. };
    6. typedef struct input ie;
    To copy to clipboard, switch view to plain text mode 

    And also
    Qt Code:
    1. void MainWindow::print()
    2. {
    3. input_events * ptr_ie;
    4. ie * ine;
    5.  
    6. QString resultString = "";
    7. for(ine=ptr_ie->l; ine; ine = ine->suiv)
    8. {
    9. ui->textBrowser->setText(ui->textBrowser->toPlainText() + resultString.setNum(ine->id) + " ");
    10. }
    11. }
    To copy to clipboard, switch view to plain text mode 

    The problem is that does not print output in function print()

    the program here <link to 3rd party site removed, use attachments instead>

    Thank you for your time
    Last edited by NewLegend; 24th July 2010 at 21:40.

Similar Threads

  1. Replies: 6
    Last Post: 28th January 2014, 11:57

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.