Results 1 to 5 of 5

Thread: How can I connect to facebook in my code?

  1. #1
    Join Date
    Apr 2011
    Posts
    11
    Thanks
    2
    Qt products
    Qt3 Qt4 Qt/Embedded Qt Jambi PyQt3 PyQt4
    Platforms
    Windows

    Default How can I connect to facebook in my code?

    i have downloaded qfacebookconnect from
    http://gitorious.org/qfacebookconnec...t/trees/master

    but an error occured during the runtime?

    :: error: cannot open file '../debug/libqfacebookconnect.a'

    .pro file:
    Qt Code:
    1. #-------------------------------------------------
    2. #
    3. # Project created by QtCreator 2009-11-20T00:54:21
    4. #
    5. #-------------------------------------------------
    6.  
    7. QT += network webkit xml
    8.  
    9. TARGET = sample
    10. TEMPLATE = app
    11. DESTDIR = ../debug
    12.  
    13. SOURCES += main.cpp\
    14. mainwindow.cpp
    15.  
    16. HEADERS += mainwindow.h
    17.  
    18. FORMS += mainwindow.ui
    19.  
    20.  
    21. INCLUDEPATH = ../inc/
    22. win32:LIBS += ../debug/libqfacebookconnect.a
    23. unix:LIBS += ../debug/libqfacebookconnect.so
    24.  
    25. symbian: {
    26. TARGET.CAPABILITY = NetworkServices # Symbian specific, we just need network access
    27. TARGET.UID3 = 0xA89FA522 # Symbian specific, unprotected uid3 from symbiansigned.com
    28.  
    29. INCLUDEPATH += /epoc32/include/stdapis # this seems to be a bug.
    30. LIBS += -lqfacebookconnect
    31.  
    32. libqfacebookconnect.sources = qfacebookconnect.dll
    33. libqfacebookconnect.path = \sys\bin
    34. DEPLOYMENT += libqfacebookconnect
    35. }
    36.  
    37. ICON = gfx/fb.svg
    To copy to clipboard, switch view to plain text mode 

  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: How can I connect to facebook in my code?

    Which part of the error message is not clear? Where is the compiled libqfacebook.a library on your system?

    BTW: The error message is not a run time error message. It is a linker error message.

  3. The following user says thank you to ChrisW67 for this useful post:

    kishoreksnair (16th September 2011)

  4. #3
    Join Date
    Apr 2011
    Posts
    11
    Thanks
    2
    Qt products
    Qt3 Qt4 Qt/Embedded Qt Jambi PyQt3 PyQt4
    Platforms
    Windows

    Default Re: How can I connect to facebook in my code?

    I am new in QT ....I have downloaded qfacebookconnect project from:
    http://gitorious.org/qfacebookconnec...t/trees/master

    there is no libqfacebook.a in our project...there are two pro files in this project such as:libqfacebook.pro and sample.pro.

    First i have run the qfacebookconnect then generate some files in debug folder:qfacebookconnect.lib,qfacebookconnect.dll,q facebookconnect.ilk etc.

    How ca i Run this project? Now i am developing a QT GUI application...i want to connect facebook in my app?? please mention steps needed for run the qfacebookconnect application..


    Added after 44 minutes:


    thank u very much.....it has been worked successfully....after copy the lib file into debug folder of sample..change the name in pro file.

    Now i have some problems in FBUserid....cannot retrieve the user id??
    Last edited by kishoreksnair; 16th September 2011 at 06:26.

  5. #4
    Join Date
    Sep 2009
    Location
    Wroclaw, Poland
    Posts
    1,394
    Thanked 342 Times in 324 Posts
    Qt products
    Qt4 Qt5
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: How can I connect to facebook in my code?

    This "Facebook" must be quite popular, two threads about it today : Error-in-retrieving-data-from-facebook-to-qt-gui-application :P
    Now i have some problems in FBUserid....cannot retrieve the user id??
    There seems to be some kind of wiki on the project site, try searching for info there.

  6. #5
    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: How can I connect to facebook in my code?

    Quote Originally Posted by kishoreksnair View Post
    I am new in QT ....I have downloaded qfacebookconnect project from:
    http://gitorious.org/qfacebookconnec...t/trees/master

    there is no libqfacebook.a in our project...there are two pro files in this project such as:libqfacebook.pro and sample.pro.

    First i have run the qfacebookconnect then generate some files in debug folder:qfacebookconnect.lib,qfacebookconnect.dll,q facebookconnect.ilk etc.

    How ca i Run this project? Now i am developing a QT GUI application...i want to connect facebook in my app?? please mention steps needed for run the qfacebookconnect application..
    qfacebookconnect is a library... you don't run libraries on their own. You build the qfacebookconnect library in the same fashion that you build the majority of Qt programs:
    Qt Code:
    1. qmake
    2. nmake (or mingw32-make)
    3. nmake install (if provided)
    To copy to clipboard, switch view to plain text mode 

    The sample directory contains an example program that is set up to look for the libraries in the folder above.

    thank u very much.....it has been worked successfully....after copy the lib file into debug folder of sample..change the name in pro file.
    If there is any chance (I suspect there is) of qfacebookconnect changing then you should change your project PRO to point LIBS at the location of the qfacebookconnect build rather than copying the library file. It is harder to get out of sync this way.

    Now i have some problems in FBUserid....cannot retrieve the user id??
    Perhaps you should ask the authors of qfacebookconnect how to use their library.

Similar Threads

  1. Connect A Database With code
    By Fk_king in forum Qt for Embedded and Mobile
    Replies: 1
    Last Post: 10th September 2011, 18:02
  2. sharing an app on facebook and twitter
    By ranjit.kadam in forum Qt Programming
    Replies: 1
    Last Post: 4th May 2011, 19:32
  3. Interfacing with the Facebook API
    By wswartzendruber in forum Newbie
    Replies: 2
    Last Post: 20th July 2009, 22:18
  4. connect qwtplot from ui with code
    By pospiech in forum Qwt
    Replies: 0
    Last Post: 9th March 2008, 17:00

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.