Results 1 to 3 of 3

Thread: VS not opening .ui files with Qt Designer

  1. #1
    Join Date
    Mar 2010
    Location
    Auckland, NZ
    Posts
    121
    Thanks
    9
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default VS not opening .ui files with Qt Designer

    I am using Qt 4.8.1 (64-bit, built from source) with Visual Studio 10 and cmake 2.8. The Qt VS add-in is 1.1.11. When I double-click on a .ui file in VS it invokes the xml editor, not Qt Designer, and Open With does not show Qt Designer in the list. This is a project that was generated by cmake from CMakeLists.txt. If I use Qt Creator everything works normally. How can I tell VS to use Qt Designer?

  2. #2
    Join Date
    Mar 2010
    Location
    Auckland, NZ
    Posts
    121
    Thanks
    9
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: VS not opening .ui files with Qt Designer

    I tried reinstalling the add-in, but it didn't make any difference.

  3. #3
    Join Date
    Mar 2010
    Location
    Auckland, NZ
    Posts
    121
    Thanks
    9
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: VS not opening .ui files with Qt Designer

    I found the answer. The CMakeLists.txt file (which I did not write) was creating a SOURCE_GROUP called "Resources" for the UI forms. I changed the name to "Forms" and now VS knows to use Designer to open the .ui files:

    ###SOURCE_GROUP("Resources" FILES
    SOURCE_GROUP("Forms" FILES
    ${ImageViewer_UI}
    )

Similar Threads

  1. Designer plugin crashes when opening *.ui
    By dimm0n in forum Qt Tools
    Replies: 2
    Last Post: 12th April 2010, 07:40
  2. Replies: 5
    Last Post: 10th November 2009, 15:46
  3. opening PPT files in Qt
    By jay in forum Qt Programming
    Replies: 5
    Last Post: 14th May 2009, 12:20
  4. QDesktopServices::openUrl() not opening files in set path
    By been_1990 in forum Qt Programming
    Replies: 2
    Last Post: 4th May 2009, 18:34
  5. Replies: 5
    Last Post: 10th May 2006, 00:20

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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.