I am trying to create an application in Android 2.2 which sends SMS to 6 different contacts the same msg automatically in background as a Service using android.telephony.SmsManager which supports both CDMA and GSM.
I saw many threads which has a code snippet but they are using which are deprecated i.e. import android.telephony.gsm.SmsManager; so i just replaced it with import android.telephony.SmsManager and wrote the following code & it works
SmsManager sms = SmsManager.getDefault();
sms.sendTextMessage(phoneNumber, null, message, sentPI, deliveredPI);
now ,
1) can anyone tell me the
roadmap to create a servicewhich sends up
to 6 SMS in background ?2) moreover is it good to create another thread inside a service to
send SMS to make it run in a separate thread for fast result ?
i am pretty much new to Android Services section so i am confused what i need to use Remote Service or Local Service , please do ask if you have any question regarding my post
1) You only need to follow the LocalService example depicted here
2) You can use any for of android concurrency as depicted here if you choose to.