I'm sure this is a problem that has been talked about in the past so my apologizes for posting about it again. I just can't find a solution.
I'm reading the inbox and get the message body correctly. But when I read the phone number I have some issues. If the SMS was sent by someone that is not on my contact list I get the phone number. But if the sender is on my contact list then I only get the name.
So: item = result.ReturnValue.getNext();
returns item = "5035551234" for a message sent by someone not on my contact list
returns item = "Joe Schmoe" for a message sent by Joe who is on my contact list.
I, however, need Joe's number. Sure I can look it up I guess, but Joe might have 5 phone numbers on my contact list. So looking up does nothing good.
Is there a way to find out what number Joe used to send that specific text message?