×

Discussion Board

Results 1 to 10 of 10
  1. #1
    Regular Contributor
    Join Date
    Nov 2006
    Posts
    98

    Exclamation Urgent Plz Help..?? Reading Sim Contacts

    Hi All,

    Iam trying to read contacts from sim memory for S60 2nd edition FP2 mobiles like(6600) using the following code..

    -----------------------------------------------------------------------
    -----------------------------------------------------------------------

    CCommsDatabase* db = CCommsDatabase::NewL(EDatabaseTypeUnspecified);
    CleanupStack::PushL(db);
    CCommsDbTableView* table = db->OpenTableLC(TPtrC(MODEM));
    table->GotoFirstRecord();
    TBuf<255> KTsyName;
    TBuf<100> name;
    table->ReadTextL(TPtrC(MODEM_TSY_NAME),KTsyName);
    // Cleanup - CommsDB no longer needed
    CleanupStack::PopAndDestroy(2); // table,db

    // Connect to the ETel server
    RTelServer aTelServer;
    User::LeaveIfError(aTelServer.Connect());
    CleanupClosePushL(aTelServer);

    User::LeaveIfError(aTelServer.LoadPhoneModule(KTsyName));


    TInt numberOfPhones;
    User::LeaveIfError(aTelServer.EnumeratePhones(numberOfPhones));


    for (TInt i=numberOfPhones; i>0; i--) {
    // Get the phone name
    RTelServer::TPhoneInfo phoneInfo;

    User::LeaveIfError(aTelServer.GetPhoneInfo(i-1,phoneInfo));

    // Open the phone by name
    RBasicGsmPhone phone;
    User::LeaveIfError(phone.Open(aTelServer,phoneInfo.iName));

    RGsmPhoneBook myBook;
    User::LeaveIfError(myBook.Open(phone, SIM_PHONEBOOK));

    RGsmPhoneBook::TEntry entry;

    TInt test = myBook.ReadFirst(entry);

    CleanupClosePushL(phone);

    name = entry.iText;

    }

    CleanupStack::PopAndDestroy(2);

    ==========================================================


    Iam getting the following error..

    ---------------------------------------------------------------------------------------------------------------------------------------------------


    CONTACTIEAPPUI.obj : error LNK2001: unresolved external symbol "public: int __thiscall RGsmPhoneBook::ReadFirst(class RGsmPhoneBook::TEntry &)" (?ReadFirst@RGsmPhoneBook@@QAEHAAVTEntry@1@@Z)
    CONTACTIEAPPUI.obj : error LNK2001: unresolved external symbol "public: int __thiscall RGsmPhoneBook::Open(class RPhone &,class TDesC16 const &)" (?Open@RGsmPhoneBook@@QAEHAAVRPhone@@ABVTDesC16@@@Z)
    CONTACTIEAPPUI.obj : error LNK2001: unresolved external symbol "public: __thiscall RGsmPhoneBook::RGsmPhoneBook(void)" (??0RGsmPhoneBook@@QAE@XZ)
    CONTACTIEAPPUI.obj : error LNK2001: unresolved external symbol "public: __thiscall RBasicGsmPhone::RBasicGsmPhone(void)" (??0RBasicGsmPhone@@QAE@XZ)


    So Plz Help me out...


    Waiting for your Valuable reply


    Thanks & Regards,
    techietintu

  2. #2
    Nokia Developer Moderator
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    28,751

    Re: Urgent Plz Help..?? Reading Sim Contacts

    In general:
    ...unresolved external symbol...
    are linker errors, they mean that you have not added some necessary libraries (containing the missing symbols) to your project. Then you should check the SDK Help, what library contains the classes.

    In this particular case RGsmPhoneBook and RBasicGsmPhone are the classes in question and they have no documentation. As a last try you can try to do a search in *.lib for the mangled symbols - as ??0RGsmPhoneBook@@QAE@XZ - or just the readable part of it - RGsmPhoneBook). However these 2 classes are not part of the publicly available S60 SDK-s.

    Also note that 6600 is a 2nd edition device without any Feature Pack.

  3. #3
    Regular Contributor
    Join Date
    Nov 2006
    Posts
    98

    Re: Urgent Plz Help..?? Reading Sim Contacts

    Hi,

    Thanks for your reply.I know libraries and header files are missing but not able to make out which libraries or header files need to be included.

    Plz let me know which libraries and header files should be included.


    Thanks & Regards,
    techietintu

  4. #4
    Regular Contributor
    Join Date
    Sep 2006
    Posts
    280

    Re: Urgent Plz Help..?? Reading Sim Contacts

    Quote Originally Posted by techietintu
    Hi,

    Thanks for your reply.I know libraries and header files are missing but not able to make out which libraries or header files need to be included.

    Plz let me know which libraries and header files should be included.


    Thanks & Regards,
    techietintu
    The Header file is etelbgsm.h and the library is gsmbas.lib.
    But these are not available in the public SDK.
    Last edited by Tina_Tibrewal; 2006-12-13 at 05:07.

  5. #5
    Regular Contributor
    Join Date
    Nov 2006
    Posts
    98

    Re: Urgent Plz Help..?? Reading Sim Contacts

    Hi,
    Thanks for your valuable reply now using that header and library file i was able to sort out that error.
    Now another error is poping up..


    Doing first-stage link by name
    link.exe @D:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\nma01388.
    Creating library \6680\series_60\EPOC32\BUILD\6680\SERIES_60\SERIES60EX\CONTACTIE\GROUP\CONTACTIE\WINS\UDEB\CONTACTIE.lib and object \6680\series_60\EPOC32\BUILD\6680\SERIES_60\SERIES60EX\CONTACTIE\GROUP\CONTACTIE\WINS\UDEB\CONTACTIE.exp
    LINK : warning LNK4005: no objects used from library \6680\series_60\EPOC32\RELEASE\WINS\UDEB\COMMDB.LIB
    CONTACTIEAPPUI.obj : error LNK2001: unresolved external symbol "public: void __thiscall RMobilePhone::GetSubscriberId(class TRequestStatus &,class TBuf<15> &)const " (?GetSubscriberId@RMobilePhone@@QBEXAAVTRequestStatus@@AAV?$TBuf@$0P@@@@Z)
    CONTACTIEAPPUI.obj : error LNK2001: unresolved external symbol "public: __thiscall RMobilePhone::RMobilePhone(void)" (??0RMobilePhone@@QAE@XZ)
    \6680\series_60\EPOC32\BUILD\6680\SERIES_60\SERIES60EX\CONTACTIE\GROUP\CONTACTIE\WINS\UDEB\CONTACTIE.APP : fatal error LNK1120: 2 unresolved externals
    NMAKE : fatal error U1077: 'link.exe' : return code '0x460'
    Stop.
    if exist "\6680\series_60\EPOC32\BUILD\6680\SERIES_60\SERIES60EX\CONTACTIE\GROUP\CONTACTIE\WINS\UDEB\CONTACTIE.exp" del "\6680\series_60\EPOC32\BUILD\6680\SERIES_60\SERIES60EX\CONTACTIE\GROUP\CONTACTIE\WINS\UDEB\CONTACTIE.exp"
    Stopped the build by removing the export object,
    if present, because the pre-link stage failed
    Linking...
    LINK : fatal error LNK1104: cannot open file "\6680\series_60\EPOC32\BUILD\6680\SERIES_60\SERIES60EX\CONTACTIE\GROUP\CONTACTIE\WINS\UDEB\CONTACTIE.exp"
    Error executing link.exe.

    CONTACTIE.APP - 5 error(s), 1 warning(s)




    Waiting for your valuable reply...


    Thanks & Regards,
    techietintu

  6. #6
    Super Contributor
    Join Date
    Oct 2005
    Location
    Hyderabad,India
    Posts
    1,156

    Re: Urgent Plz Help..?? Reading Sim Contacts

    seems like a link error..check whether you have those lib's in the mmp file and re import your application.

    Priju

  7. #7
    Regular Contributor
    Join Date
    Nov 2006
    Posts
    98

    Re: Urgent Plz Help..?? Reading Sim Contacts

    Hi,

    I have added the following libraries..

    LIBRARY euser.lib
    LIBRARY apparc.lib
    LIBRARY cone.lib
    LIBRARY eikcore.lib
    LIBRARY eikcoctl.lib
    LIBRARY avkon.lib
    LIBRARY eikctl.lib
    LIBRARY bafl.lib
    LIBRARY cntmodel.lib
    LIBRARY CommonDialogs.lib
    LIBRARY efsrv.lib gsmadv.lib
    LIBRARY estor.lib commdb.lib etel.lib gsmbas.lib



    But Still facing the same errors.Plz tell me which libraries and header files need to be included.


    thanks & Regards,
    techietintu

  8. #8
    Nokia Developer Champion
    Join Date
    Mar 2006
    Location
    Helsinki, Finland
    Posts
    8,347

    Smile Re: Urgent Plz Help..?? Reading Sim Contacts

    Hi,
    Quote Originally Posted by techietintu
    Hi,

    I have added the following libraries..

    LIBRARY euser.lib
    LIBRARY apparc.lib
    LIBRARY cone.lib
    LIBRARY eikcore.lib
    LIBRARY eikcoctl.lib
    LIBRARY avkon.lib
    LIBRARY eikctl.lib
    LIBRARY bafl.lib
    LIBRARY cntmodel.lib
    LIBRARY CommonDialogs.lib
    LIBRARY efsrv.lib gsmadv.lib
    LIBRARY estor.lib commdb.lib etel.lib gsmbas.lib



    But Still facing the same errors.Plz tell me which libraries and header files need to be included.


    thanks & Regards,
    techietintu
    Add an entry for etelmm.lib.

    Regards.
    Kiran.

  9. #9
    Regular Contributor
    Join Date
    Nov 2006
    Posts
    98

    Re: Urgent Plz Help..?? Reading Sim Contacts

    Hi All,

    Thanks Kiran for your valuable reply.Now the code is compiling without errors and i'm also able to create sis file for it.But on the device(6600) it is not reading the contacts from sim memory.
    Any idea on this plz reply.


    Thanks & Regards,
    Techietintu

  10. #10
    Regular Contributor
    Join Date
    Nov 2006
    Posts
    98

    Re: Urgent Plz Help..?? Reading Sim Contacts

    Hi All,
    Anybody plz reply for my above question its reallt urgent..


    Thanks & Regards,
    Techietintu

Similar Threads

  1. Reading contacts from sim
    By srkreddy999 in forum Symbian User Interface
    Replies: 6
    Last Post: 2007-03-01, 08:04
  2. Reading SIM contacts: working!
    By fabionokia in forum Symbian
    Replies: 4
    Last Post: 2006-12-12, 16:16
  3. Reading contacts from SIM in the 6510, using VB6 and SDK 3.0
    By stile in forum PC Suite API and PC Connectivity SDK
    Replies: 2
    Last Post: 2006-12-06, 10:22
  4. Reading SIM contacts on Series 80
    By hesham.galal in forum Symbian User Interface
    Replies: 4
    Last Post: 2005-01-13, 11:58
  5. Accessing SIM contacts
    By micmen in forum Symbian
    Replies: 0
    Last Post: 2004-07-22, 07:49

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×