unresolved overloaded function type error

  • Hi All,

    I have this error after I wrote the code

    frmmain.cpp:78: error: no match for 'operator==' (operand types are '<unresolved overloaded function type>' and 'QString')
    if (window->windowTitle == Form_Header)

    QMdiSubWindow *frmMAIN::findMdiChild(QString Form_Header)
        foreach (QMdiSubWindow *window, ui->mdiArea->subWindowList())
            if (window->windowTitle == Form_Header)
                return window;
        return 0;
    How to cast I don't have a clue?

  • Hi,

    you have missing parenthesis in

    if (window->windowTitle == Form_Header)

    should be

    if (window->windowTitle() == Form_Header)

  • Thanks man...

    Can't believe myself!!

Log in to reply

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.