Results 1 to 2 of 2

Thread: Program crash- unable to detect the issue

  1. #1
    Join Date
    Sep 2015

    Default Program crash- unable to detect the issue

    The following code is giving me an issue.

    Qt Code:
    1. void MainWindow::onDelete()
    2. {
    4. if(ui->tableWidget->selectionModel()->hasSelection()){
    6. QItemSelectionModel *selectionmodel =ui->tableWidget->selectionModel();
    7. QModelIndexList selected_items= selectionmodel->selectedRows();
    8. qSort(selected_items);
    9. }
    To copy to clipboard, switch view to plain text mode 

    Whenever I run it, the program crashes giving me an error:
    Invalid address specified to RtlValidateHeap( 006A0000, 00F4DB90 )

    It appears to be trying to delete a node from the code in qlist. I am unable to figure out the error. Any advice would be great.

  2. #2
    Join Date
    Jan 2006
    Graz, Austria
    Thanked 1,544 Times in 1,494 Posts
    Qt products
    Qt3 Qt4 Qt5
    Unix/X11 Windows

    Default Re: Program crash- unable to detect the issue

    What do you want to achieve by sorting model indexes?
    You are aware that this is only for usage with QMap, right?


Similar Threads

  1. Replies: 12
    Last Post: 17th June 2013, 22:20
  2. Replies: 9
    Last Post: 31st May 2010, 15:56
  3. Unable to detect the library on QT compilation
    By rhonaldmoses in forum Newbie
    Replies: 1
    Last Post: 16th August 2008, 22:01
  4. Detect platform where my QT4 program is running on
    By the_bis in forum Qt Programming
    Replies: 1
    Last Post: 14th September 2007, 13:01
  5. Program crash
    By Pragya in forum Qt Programming
    Replies: 7
    Last Post: 29th June 2007, 08:37

Tags for this Thread


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.