How to fill a string with data from intercept message received ??

camolas

Member
Licensed User
Longtime User
Hi there,

Im very :sign0104: at this and i need you Masters hellp to keep going with this project. I can intercept message received (sms.From, Date(sms.DateReceived), Time(sms.DateReceived), sms.Body )

part of the code
....................................................................
intercept_MessageReceived
sms.Value = intercept.ReceivedMessage
textBox1.Text = sms.From
textBox2.Text = Date(sms.DateReceived)
textBox3.Text = Time(sms.DateReceived)
textBox4.Text = sms.Body

End Sub
.....................................................................

but i need ( i think ) to put this data into to a string/array from then use like this " if sms.Body = Hello then do some thing", if sms.From = xxxxxxx then do some thing ..... Please hellp give me a example for me to add to this simple program.


Thankz e sory :sign0104:
 

mjcoon

Well-Known Member
Licensed User
Are you saying that (the rather obvious)
B4X:
Dim bodyString As String
bodyString = sms.Body

does not work for you? (Or is not what you want?)

(N.B. I have no interest or experience with SMS library.)

Mike.
 

camolas

Member
Licensed User
Longtime User
Hi,

Thanks for the hellp, example if i get in the sms.Body " Hello Ten Go Still" and i need to use the four words..

Like this:

if sms.Body (1 word)="Hello" then ....
if sms.Body (2 word)="Then" then ....
if sms.Body (3 word)="Go" then ....
if sms.Body (4 word)="Still" then ....

Can you hellp?

Thanks,
 
Top