Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Update $(Qt_IncludePath_) in visual studio after updating qt installation



  • Just updated my installation from 5.14.1 to 5.14.2(prebuilt windows binaries) and now i have a problem. I'm using visual studio with qt addon, did update paths in "Extensions -> Qt vs tools -> qtoptions" but project created before update still has $(QT_INCLUDEPATH_) set to 5.14.1 paths which is not exists anymore (preview from macro viewer).
    At the same time, in fact project is builds with 5.14.2 but wrong macro definition breaks code highlighting. Can't find any ways to edit\update macro. Any ideas? Thanks in advance.

    //ps. Thankyou for edit which makes my question being unreadable and lose comment to picture. I insist on named link instead of inplace picture.



  • For the record, if anybody's having this same problem:
    In Solution Explorer, right click on the project name -> Qt -> "Upgrade to latest Qt project format version".

    P.S. I'm using VS2019 and Qt extension version is 2.5.1.



  • For the record, if anybody's having this same problem:
    In Solution Explorer, right click on the project name -> Qt -> "Upgrade to latest Qt project format version".

    P.S. I'm using VS2019 and Qt extension version is 2.5.1.



  • Hello,

    I am having the same problem.
    And @codebit solution is not helping in my case: there is no such an option as "Qt -> "Upgrade to latest Qt project format version"

    6808e994-e9d6-4330-aa15-18e05a3b89d5-image.png

    Any ideas where I should change it?

    The only option I see now is to create an empty project, where i checked it is working fine, and move files from my project there.

    Mikl



  • Hello,

    I solved it

    "Change Solution Qt version" to $(DefaultQtVersion) and back with a restart in between made a trick.


Log in to reply