×

Discussion Board

Results 1 to 6 of 6
  1. #1
    Registered User
    Join Date
    Feb 2008
    Posts
    3

    How to read incoming sms, its going by default in handset inbox, how do i get sms....

    Hello,
    I want to receive sms by my J2ME Application, i am using default example coming with NetBeans IDE but when i tried it on my Sony Erricson W550 and Nokia 6600, it directly goes to handset inbox instead of my application. Is there any way to get newly received sms into application, and then read that sms. Its SMS not MMS, so just text will matter,
    I m in trouble due to this problem, please save me, your replies will be very helpful for me.....
    Thanks in Advance


    Mayur
    Mayur Patil
    MCSD.Net
    Web Developer

  2. #2
    Super Contributor
    Join Date
    Apr 2003
    Location
    USA, CA
    Posts
    7,191

    Re: How to read incoming sms, its going by default in handset inbox, how do i get sms

    You can only receive SMS/MMS messages which are sent to the same port which your MIDlet is listening to. You cannot receive/intercept normal messages. They will always go to the inbox directly

    Hartti

  3. #3
    Registered User
    Join Date
    Apr 2008
    Posts
    2

    Re: How to read incoming sms, its going by default in handset inbox, how do i get sms

    Harttie,

    I have a commercial application that intercepts all incoming sms's and depending on their content sorts them accordingly. If there is no port to listen to all incoming sms, how would you envisage these guys accomplished this?

  4. #4
    Super Contributor
    Join Date
    Mar 2003
    Location
    Finland
    Posts
    9,563

    Re: How to read incoming sms, its going by default in handset inbox, how do i get sms

    The probably didn't write it in Java. In other words, it is probably a native C++ Symbian app, and you're using it on a Symbian based phone. Right?

  5. #5
    Registered User
    Join Date
    Apr 2008
    Posts
    2

    Re: How to read incoming sms, its going by default in handset inbox, how do i get sms

    Probably right, thanks :-)

  6. #6
    Regular Contributor
    Join Date
    Nov 2008
    Posts
    81

    Re: How to read incoming sms, its going by default in handset inbox, how do i get sms

    Hi,
    I was experimenting on sms message for N72 device.
    And I have done very well, I can read message all body, can get sender number and Bla Bla Bla.
    If you need than I can send you the code which I used.
    Look at here;
    CMsvEntry* serverEntry = iSession->GetEntryL( aEntryId ); // current entry
    CleanupStack::PushL( serverEntry );
    TMsvEntry entry = serverEntry->Entry(); // currently handled message entry
    //serverEntry->DeleteL(aEntryId);
    //CleanupStack::PopAndDestroy(serverEntry);

    entry.SetNew( ETrue );
    entry.SetUnread( ETrue );
    entry.SetVisible( ETrue );
    const TDesC& descp = entry.iDescription; // iDescription will have only first 32 characters from the message
    TBuf8<40> MessageArrived;
    MessageArrived.Copy(descp);
    serverEntry->ChangeL( entry ); // commit changes Rajat
    iSmsMtm->SwitchCurrentEntryL(aEntryId);
    iSmsMtm->LoadMessageL();
    CSmsHeader& header = iSmsMtm->SmsHeader();
    CRichText& richText = iSmsMtm->Body();
    TPtrC s3 = iSmsMtm->Body().Read(0);
    TDesC& s2 = s3; //_L8( iSmsMtm->Body());
    TPtrC from = header.FromAddress();
    const TDesC& phoneNumber = from;
    _LIT(s1, "Rajat");
    CAknInformationNote* informationNote = new ( ELeave ) CAknInformationNote;
    informationNote->ExecuteLD( s2 );
    CleanupStack::PopAndDestroy( serverEntry );

    I hope It will useful to you to overcome from your problem.
    Thanks
    Bye
    Regards Rajat.

Similar Threads

  1. Replies: 1
    Last Post: 2005-12-01, 23:57
  2. New message in SMS Inbox
    By isseyp in forum Mobile Java General
    Replies: 4
    Last Post: 2004-05-07, 14:45
  3. using java to read sms inbox ?
    By fekimoki in forum Mobile Java General
    Replies: 0
    Last Post: 2004-01-03, 08:16
  4. AT Command to automatically recognize incoming SMS
    By tquantero in forum General Messaging
    Replies: 4
    Last Post: 2003-07-21, 07:25

Posting Permissions

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