Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. MSVC 2012 with Qt 5 Add-In 1.2.4 Cannot build New Projects
Forum Updated to NodeBB v4.3 + New Features

MSVC 2012 with Qt 5 Add-In 1.2.4 Cannot build New Projects

Scheduled Pinned Locked Moved General and Desktop
5 Posts 3 Posters 3.3k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    jzuber
    wrote on last edited by
    #1

    Hi,

    I have been scouring the web to try to resolve this but have had no luck. What I have done is installed a fresh version of MSVC2012, which I then updated. I also installed the latest Qt (5.4) and the new Qt Add in (1.2.4). When I try to build a project now, I select the "Qt Application" option, give the project a name, select the QT items I need and click finish. I then get a MSVC error: "Object reference not set to an instance of an object". I have noticed that in an existing project, there is a xxx.vcxproj.user file which contains the definition of the "QTDIR". In this instance, after I get the error there is a .vcxproj and a .vcxproj.filters file (also .sdf and .opensdf files). There are no other files generated and the project is not created within MSVC.

    I have checked that I am using the correct Qt version under QT5... Qt Options. I am able to run this correctly in MSVC 2010. I know this problem is related to MSVC but I can buil a regular win32 project in MSVC 2012 - it seems to be an issue with the Qt5 Add-In and MSVC 2012.

    Thanks for reading!

    1 Reply Last reply
    0
    • W Offline
      W Offline
      wilcroft
      wrote on last edited by
      #2

      Hey,

      I also recently installed the same (VS2012 and Qt Add-in 1.2.4) and am getting the same errors as you! So, you're not alone.

      While doing some digging of my own, I stumbled across the Qt Add-In bug tracking page. It looks like 1.2.4 is broken with VS2012 (but not VS 2013). Apparently, 1.2.3 will work though (I can't confirm yet, however).

      Here's the link: https://bugreports.qt.io/browse/QTVSADDINBUG-392?jql=project = QTVSADDINBUG

      Cheers,
      Wilcroft

      1 Reply Last reply
      0
      • Chris KawaC Offline
        Chris KawaC Offline
        Chris Kawa
        Lifetime Qt Champion
        wrote on last edited by
        #3

        This might indeed be an add-in problem, but lets exclude other possibilities.
        To clarify - You've installed VS2012 Update 4?
        Can you try an older version of the add-in (found "here":http://download.qt.io/official_releases/vsaddin/)?
        Do you have any other extensions installed?
        Does it happen for example when you import an existing Qt Creator project (.pro)?
        Can you try to run VS as admin and see if the problem remains?

        1 Reply Last reply
        0
        • W Offline
          W Offline
          wilcroft
          wrote on last edited by
          #4

          I can't speak for the OP, but in my experience:
          [quote author="Chris Kawa" date="1422379274"]This might indeed be an add-in problem, but lets exclude other possibilities.
          To clarify - You've installed VS2012 Update 4?[/quote]Yup.
          [quote]Can you try an older version of the add-in (found "here":http://download.qt.io/official_releases/vsaddin/)?[/quote]Just installed 1.2.3, and it does work. I also get the various Qt-related options when right-clicking on a qt-project in the solution explorer, which I didn't get with 1.2.4
          [quote]Do you have any other extensions installed?[/quote] Nope.
          [quote]Does it happen for example when you import an existing Qt Creator project (.pro)?[/quote] Yep. Import errors just like new project creation.
          [quote]Can you try to run VS as admin and see if the problem remains?[/quote]No change.

          1 Reply Last reply
          0
          • J Offline
            J Offline
            jzuber
            wrote on last edited by
            #5

            wilcroft, thanks for the above answer as my answers are identical.

            1 Reply Last reply
            0

            • Login

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups
            • Search
            • Get Qt Extensions
            • Unsolved