×

Discussion Board

Results 1 to 3 of 3
  1. #1
    Super Contributor
    Join Date
    Feb 2004
    Location
    Dallas
    Posts
    605

    Application crashes on Loading TSY

    My Application crashes on
    Code:
    User::LeaveIfError(server.LoadPhoneModule(KGsmModuleName));
    where
    Code:
    _LIT(KGsmModuleName, "phonetsy.tsy");
    dont know the reason ??? Can someone tell me ?

  2. #2
    Nokia Developer Expert
    Join Date
    Aug 2004
    Posts
    53
    Hi,

    Below is a sample that u may refer to:

    RTelServer server;

    // connect to server
    User::LeaveIfError(server.Connect());
    CleanupClosePushL(server);

    User::LeaveIfError(server.LoadPhoneModule(KTsyModule));

    // Enumerate available phones
    TInt numPhones;
    User::LeaveIfError(server.EnumeratePhones(numPhones));
    if (numPhones < 1)
    {
    User::Leave(KErrNotFound);
    }

    // Get phone info
    RTelServer::TPhoneInfo phoneInfo;
    User::LeaveIfError(server.GetPhoneInfo(0, phoneInfo));

    // Open phone
    RPhone phone;
    User::LeaveIfError(phone.Open(server, phoneInfo.iName));
    CleanupClosePushL(phone);

    // Get line info
    RPhone::TLineInfo lineInfo;
    User::LeaveIfError(phone.GetLineInfo(0, lineInfo));

    // Open a line
    RLine line;
    User::LeaveIfError(line.Open(phone, lineInfo.iName));
    CleanupClosePushL(line);

    //Open a new call on this line
    TBuf <256> callName;
    RCall call;
    User::LeaveIfError(call.OpenNewCall(line, callName));
    CleanupClosePushL(call);
    // make the call
    User::LeaveIfError(call.Dial(KPhoneNum));
    CleanupStack::PopAndDestroy(3);
    User::LeaveIfError(server.UnloadPhoneModule(KTsyModule));
    CleanupStack::PopAndDestroy(&server);

  3. #3
    Super Contributor
    Join Date
    Feb 2004
    Location
    Dallas
    Posts
    605
    Thnx Ekhoo,
    I have made the RTelServer and RMobilePhone the members of the class unlike ur case where u r making it an automatic variable.

    So in that case , will the error handling be same ? as that is something which is creating the issue ..

Posting Permissions

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