This week's book giveaway is in the Kotlin forum.
We're giving away four copies of Kotlin in Action and have Dmitry Jemerov & Svetlana Isakova on-line!
See this thread for details.
Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

extract missed call numbers and time  RSS feed

 
sam liya
Ranch Hand
Posts: 1271
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I need to get details from SMS.When we received missed call alert,i need to get callers phone numbers and time for each.Below is the example SMS Alert for missed call.



I am able to get whole SMS..but i need to show "772070614 called you 11/07 20:14".
how to extract them from SMS?
 
Ulf Dittmer
Rancher
Posts: 42972
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A combination of String.indexOf(...) and String.substring(...) ?
 
Marco Ehrentreich
best scout
Bartender
Posts: 1294
IntelliJ IDE Java Scala
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Or with capture groups in a regular expression.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!