Results 1 to 3 of 3

Thread: using QVTKWidget under QtCreator : link error

  1. #1
    Join Date
    Sep 2012
    Posts
    9
    Qt products
    Platforms
    Windows

    Default using QVTKWidget under QtCreator : link error

    Hi all,
    I tried to use QVTKWidget in my application. I used the design to promote the class QVTKWidget to my widget.But, when i compile my program, i got this error:
    Qt Code:
    1. FenClient.obj:-1: erreur : LNK2019: unresolved external symbol "public: __thiscall QVTKWidget::QVTKWidget(class QWidget *,class QFlags<enum Qt::WindowType>)" (??0QVTKWidget@@QAE@PAVQWidget@@V?$QFlags@W4WindowType@Qt@@@@@Z) referenced in function "public: void __thiscall Ui_FenClient::setupUi(class QWidget *)" (?setupUi@Ui_FenClient@@QAEXPAVQWidget@@@Z)
    To copy to clipboard, switch view to plain text mode 

    and this one :
    Qt Code:
    1. release\client.exe:-1: erreur : LNK1120: 1 unresolved externals
    To copy to clipboard, switch view to plain text mode 
    Even, when i add the libs to my .pro file , i still have these errors :
    Qt Code:
    1. LIBS += -LC:/vtkqt/lib/vtk-5.8 -lvtkWidgets \
    2. -LC:/vtkqt/lib/vtk-5.8 -lvtkCharts \
    3. -LC:/vtkqt/lib/vtk-5.8 -lvtksys \
    4. -LC:/vtkqt/lib/vtk-5.8 -lvtkGeovis \
    5. -LC:/vtkqt/lib/vtk-5.8 -lvtkViews \
    6. -LC:/vtkqt/lib/vtk-5.8 -lvtkInfovis \
    7. -LC:/vtkqt/lib/vtk-5.8 -lvtkVolumeRendering \
    8. -LC:/vtkqt/lib/vtk-5.8 -lvtkHybrid \
    9. -LC:/vtkqt/lib/vtk-5.8 -lvtkRendering \
    10. -LC:/vtkqt/lib/vtk-5.8 -lvtkGenericFiltering \
    11. -LC:/vtkqt/lib/vtk-5.8 -lvtkGraphics \
    12. -LC:/vtkqt/lib/vtk-5.8 -lvtkIO \
    13. -LC:/vtkqt/lib/vtk-5.8 -lvtkCommon \
    14. -LC:/vtkqt/lib/vtk-5.8 -lvtkProj4
    To copy to clipboard, switch view to plain text mode 
    I will appreciate all suggestions, thanks

  2. #2
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: using QVTKWidget under QtCreator : link error

    If you have not already, you need to rerun qmake after making the PRO file changes. BTW you only need the -L option once.

    It looks like you have included all the VTK libraries. Is the library containing QVTKWidget part of VTK or a separate add-on? Is it present in LIBS?

  3. #3
    Join Date
    Sep 2012
    Posts
    9
    Qt products
    Platforms
    Windows

    Default Re: using QVTKWidget under QtCreator : link error

    Quote Originally Posted by ChrisW67 View Post
    If you have not already, you need to rerun qmake after making the PRO file changes. BTW you only need the -L option once.

    It looks like you have included all the VTK libraries. Is the library containing QVTKWidget part of VTK or a separate add-on? Is it present in LIBS?
    Hi , i found just QVTKWidgetPlugin.lib, and when i linked it, i got the same error

Similar Threads

  1. Replies: 2
    Last Post: 4th April 2012, 18:01
  2. QVTKWidget
    By floyd.pepper in forum Newbie
    Replies: 1
    Last Post: 7th March 2012, 14:15
  3. QTCreator GUI How to link button with textarea
    By chs in forum Qt Programming
    Replies: 8
    Last Post: 23rd May 2011, 07:30
  4. Replies: 11
    Last Post: 5th May 2011, 14:05
  5. QtCreator change in lib should force a link
    By Braunstein in forum Qt Tools
    Replies: 1
    Last Post: 19th March 2010, 20:27

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.