Android : Best Way For Web Service Calls

Jun 10, 2010

I have been trying to develop an android application for sometime now and i would like to get some suggestion on the best way of making web service calls or to be generic the best way of communication between the android platform and web server. Soap(using Ksoap) and HTTP(using POST) are two methodologies & XML and JSON are the two data formats that am aware of,(let me know if they are few other options too..) and , i would like to know what is the best option of data transfer when i) the data to transfer is Large and less frequent. ii) more frequent but less data is being transfered. Also when it comes to data synchronization between server and our app , how is that generally implemented?

Android : Best way for web service calls


Game :: Android A Synchronous Service Calls Strategy

Sep 29, 2009

Client makes remote call to the service (returns void) and provides a callback object Service executes some long running logic on the background thread and then uses callback object to trigger ether success or failure which (since these manipulate visual elements) The scenario runs fine. The question is - can I use AsyncTask to make code less verbose (how?) and would be there any advantages in doing it
that way Or should I just get away from client callbacks alltogether and execute remote service calls retrofitted to return some value.

View 2 Replies View Related

Android :: How To Keep Service Running To Listen For Incoming And Outgoing Calls?

Sep 28, 2010

how should I create a service that would keep on running in the Background and listen for incoming and outgoing calls? I don't want the service to die at any point in time.I have created a Broadcast Receiver in my service class that is set for ACTION_PHONE_STATE_CHANGED action.In my BroadcastReceiver, I have set up a PhoneStateListener that would listen for changes in phone states.Is this the right approach?

View 3 Replies View Related

Android :: Suggestions To Remove On Boot Service To Detect Incoming Calls

Jul 14, 2010

I have gone through many threads in this group about avoiding the use of everlasting Services, Timer/TimerTask sleep issues and detecting phone calls, but not finding the answers I am looking for this app, I will really appreciate any help you can provide me. I am working on an App to detect incoming calls and when the call time is equal to 5 minutes indicate the user by vibrating the phone. In my strategy I am creating a Receiver that listens for RECEIVE_BOOT_COMPLETED action and launch an everlasting Service which sets up a PhoneState Listener.

1) Is there any other strategy to be always listening for incoming calls and thus avoide to using an on boot created Service? (besides the Service eventually gets killed and I am not able to detect incoming calls) A first approach I took here was setting up a Timer and TimerTask when CALL_STATE_RINGING state was detected and after 5 min (if the call continues) vibrate the phone for 2 seconds. However sometimes the timer phone vibrates after an hour a call was placed (the vibration happens in the run() TimerTask method. I know Android can go to sleep and that could be the reason my timer is not run on time but 2) How can Android be slept if I am in a call? Is the call just handled by the modem or how come? Next, to overcome this issue I tried preventing the Service from going to sleep by putting it in foreground state calling startForeground (NOTIFICATION_ID , notification), still the same behaviour the timer is run long after the call was placed 3) does startForeground prevent Android going to sleep or it is just aimed to keep the Service's process in memory? 4) A wake lock would do this job ? (I have not tried this) Encouraged by many post I tried using an Alarm and it works (thought I do not want to use it because I think it should be possible to accomplish with something lighter) but when the phone vibrates it just keeps vibrating till I remove the phone from my cheek (the screen is turned on again) 5) Why? Is it that Android started vibrating the phone and then went to sleep? so the vibration is turned off when Android awakes, when the screen is turned on again? 6? Ideas of how to stop the timer?

View 3 Replies View Related

HTC Desire :: Limited Service Emergency Calls Only

Nov 3, 2010

Let's start from first: I bought a t-mobile desire from someone. when I got it, it was rooted and an official htc middle east rom flashed on it (...and unrooted).Both seller and me have a local sim card (Not t-mobile) but it worked for him and not for me.It displays a "Limited Service", "Emergency Calls Only" message. when I search for operators it list my operator but when I choose that android can't register on it.

1. I rooted it again and flashed LeeDroid rom on it but no success

2. Seller did a hard reset before giving it to me (I guess it generated the problem)

3. Sim card is correct

4. Seller is not scam!

View 3 Replies View Related

HTC Hero : No Service - Calls And SMS - But Mobile Data Works

Dec 1, 2009

My Orange UK Hero is unable to make/send calls or send/receive sms. It displays "No Service" on the lock screen but mobile data seems to work perfectly.
If I go to...

Settings->Wireless Controls->Mobile Network Settings->Network Operators->Search Networks

then select Orange, it says "Your SIM card does not allow a connection to this network"

If mobile data wasnt working then I would guess that its a SIM issue but I'm clearly connected to the network as im using their internet!

Just swapped SIM with a friends phone.
My SIM works in his phone and his SIM has the same issues in my phone.

Booting up, it was connected to the network for enough time for it to get a voicemail notification but showed "No Service" straight away.

Im guessing the best bet is to re-flash with the latest Hero Orange firmware. Any tips for backing up numbers/sms/cal etc?

View 3 Replies View Related

Sprint HTC Hero :: Phone Refused To Make Calls / Had Service

Dec 22, 2009

I had a weird issue that has sprung up twice now with making phone calls and I wanted to see if anyone else was experiencing the same thing. Visually everything looks like it is functional with my phone service on the phone. I have bars, nothing out of the ordinary. However, I can't make any outbound calls either through my contacts or by manually dialing. I the number pad and it makes the response noise but doesn't actually type the number. In contacts, I hit call and the same thing happens. The fix I have found is just to soft boot the phone. Now I hear you all saying "No big deal, just restart." Yeah, it is no big deal unless I have to make a call in an emergency say calling 911 or things of that nature. Waiting for 5 minutes for my phone to reboot in an emergency can cost lives. I know I am being a little dramatic, but c'mon, at the end of the day, it is a phone and it is having trouble making calls.

View 2 Replies View Related

Android :: Showing Toasts In A Service From Worker Threads With Service Reference

Jun 24, 2009

I have a service running in the background.I have a background thread that gets a reference to the service from the application's main activity. But when the background thread calls a method in the service to display a toast, I get the "Looper not initialized exception".Why,if I have a valid, bound reference to a Service, does this still happen?

View 4 Replies View Related

Android :: Unable To Start Service Intent Service Not Found

Aug 20, 2009

I am getting following message when i try to launch service.Also is there any specific path on file system where we need to place the .apk file which contains my serivce component only.

View 2 Replies View Related

Android :: Service Auto Restarts On Breakpoint When Debugging A Service

Jul 22, 2010

I am trying to run the sample soft keyboard included in the SDK. I am using the debugger, and the literature says that to use a breakpoint while debugging a SERVICE, I need to include:

android.os.Debug.waitForDebugger();

So here is the portion of the code I modified:

CODE:...........

I have put a couple of breakpoints, at the statements indicated by the comments.

This is what happens: the debugger first stops at the breakpoint1, for a few seconds. But then the service restarts. For the life of me I can't figure out what makes the service to restart.

View 3 Replies View Related

Android :: How To Get Interface On Service Without Destroying Service At Unbind?

Mar 1, 2009

My service works exactly the way i want as long as i use start and stop and communicate using intents. However my activity needs to change the state of my service as well as retrieving state information.So i thought it would be nice to broadcast some kind of state_changed event from my service and use a binder interface to pull information from the service or change the services state based on user input.This works fine too. The only problem is that my service gets killed when i unbind it just as the documentation says.Is there any way to keep the service alive but still get an interface to control it directly. My activity offers the user a way to stop the service and the service kills itself anyway after it's work is done but i don't want the service to stop every time the activity is destroyed.

View 3 Replies View Related

HTC Droid Eris :: Calls Do Not Even Show Up - Appear As Missed Calls

Jul 3, 2010

Not sure if this is technically the "silent bug" but calls do not even show up on the phone, they just appear as "missed call from...." no noise no other notification. I restarted phone but it did it again right away. Phone does show the 50% bug in battery info.

View 1 Replies View Related

Android :: Local Service Vs Remote Service

Nov 9, 2010

I'm confused about whether I need to run my service in a separate process. What are the advantages / disadvantages of each?For reference I'm trying to create an App that uses a service to play [streaming] audio in the background. So which one is better for my use case?

View 1 Replies View Related

Android :: Two Threads And 1 Service / Or Service Per Thread?

Nov 20, 2010

what I'm trying to do here is implement something like a peer-to-peer client. Being that, it will start a client thread and a server thread.I know Services themselves run in the main GUI thread, so I'll have to start a couple of independent threads (or Asynctasks?) for each server and client. The only thing I'm not so sure about is if I'll better have 1 Service starting 2 threads, or maybe 2 services, each one of them starting their own thread.

View 2 Replies View Related

Android :: Get System Service In Personal Service?

Nov 30, 2009

I got an problem on getting the TelephonyManager in my personal service. The code as below: public class MyService extends Service {@Override public IBinder onBind(Intent intent) { return mBinder;}

View 4 Replies View Related

Android :: Does Service Have To Be Remote Service Or Can It Still Be Local?

Sep 30, 2009

i have an app that binds to a local service.I want to add a desktop widget that binds to the same service. does my service have to be a remote service or can it still be local?if it can still be local, how can I get at the local binder?

View 2 Replies View Related

Android :: Bind To A Service From Another Service On Droid?

Sep 30, 2010

Please show me how to bind to a Service from another Service on Android.
If you have an image to show how to do.

View 1 Replies View Related

HTC EVO 4G :: Make VoIP Calls Or Skype Out Calls

Jun 9, 2010

Is there anyway to make VoIP calls or Skype Out calls on the EVO? I am switching from the iPhone 3GS and am going out of the country on vacation in a month and I got used to making Skype Out calls over WiFi when out of the country.

View 3 Replies View Related

HTC Incredible :: Not Receiving Calls - Log As Missed Calls

Apr 30, 2010

having problems receiving calls. When I call the phone from another line, nothing happens except its logged as a missed call. The screen doesnt light up and no options for receiving calls. This happened before I installed Google voice. I disabled Google voice and still no joy. Everything else works. I can make calls, browse over WiFi and 3G.

View 8 Replies View Related

Android :: Tips On Making An Android Service / Which Polls Web Service Handle Bad Connectivity

Jul 16, 2010

I am developing an Android app which needs to poll a specific webpage in time intervals. I've got it to the point where it does indeed poll the page on a specific interval, and that interval is specified in a SharedPreference which can be changed by the user in the settings page of the app. But complications arise when network connectivity is flaky.For example, how do I ensure that the Service "wakes up" the network adapter and gives it ample time to connect before polling the page, in the case that the phone was sleeping to save power? This polling action can happen as little as once every 24 hours, so I don't want to miss one action just because the network was out (but turned on a few seconds, minutes, or even hours later).

Or there are times when the web service doesn't respond, or DNS doesn't respond, or what have you, and for any reason it doesn't get a response even though the phone is technically connected. What sort of rule do I put in place to make this retry later, so that I'm not retrying repeatedly when the user specifically turned off their internet but I'm retrying soon enough that if it was just a hiccup, the data can be received soon after the first try?Are there any examples for this type of situation? What is the logic to best handle this?

View 1 Replies View Related

Android :: Android Remote Service Doesn't Call Service Methods

May 28, 2010

I'm developing a GPS tracking software on android. I need IPC to control the service from different activities. So I decide to develop a remote service with AIDL.This wasn't a big problem but now it's always running into the methods of the interface and not into those of my service class. Maybe someone could help me?If i now try to call a method from an activity for example start(trackId) nothing happens. The binding is OK. When debugging it always runs into the startTracking() in the generated ITrackingServiceRemote.java file and not into my TrackingService class. Where is the problem? I can't find anything wrong.

View 1 Replies View Related

Android :: Service Stopping Another Service

Feb 17, 2010

i have a question about Services in Android.I have a application with two Services A and B.Is it possible that Service A can stop Service B?I dont want to do it through a Activity, cause the Application will be in Background. If some special Event happen in Service A, then it should tell Service B to stop. How can i do that?

View 1 Replies View Related

General :: Galaxy S2 - Service State Says Out Of Service Or Radio Off

Jan 10, 2014

I have a galaxy s2 and after I installed costom roms I dont have any signal what so ever.

I tried with like 3 roms and the same result.

I tought it was a modem problem and I tried to install some modems and see if that works. But it didnt.

My Service State says Out of service and sometimes it says Radio off.

View 1 Replies View Related

Android :: Call A Service Hosted In A Windows Service From Android

Jun 3, 2010

I hosted my service WCF (.net) using a windows service,i can access to the service from any browser but when i tried to call it from android it doesn't respond. it works fine before the hosting procedure (i used host client by default on Visual Studio).The url that i try to attempt is from android emulator, and installed my webservice in the same local machine(endpoints address http://localhost.).

View 7 Replies View Related

Android :: Calls Over 3G

Aug 24, 2010

I've been doing my research on the subject but I have time believing that there is no services that will allow me to me 3G calls with my Nexus One (it is my understanding that with the iPhone there are several services that offer that). Is that true??? I'm in Canada so the Google Voice service is not an option.

View 18 Replies View Related

Android :: Set Weight Using API Calls

Sep 7, 2009

is there a way to set the weight of a view using API calls? I construct parts of my UI at runtime. The dynamic UI has multiple View. However, I want to set the weight of those view to be non-equal. Any idea on how to do that?

View 6 Replies View Related

Android :: Record Calls

Jan 24, 2009

I would like to know whether its possible to record call in Android. If its possible then which class should be used for that purpose. I think there should be some message broadcast receiver invoked when a call is accepted and application should be started in background and record the conversation. Would like to know if this is actually possible and it it is then what classes to refer to?

One more thing if I want to send the recorded file to a server through GPRS then is there any limit in size for it to get transfer through GPRS? Small files will be transferred easily through GPRS but what about larger files? Is there any upper limit as to files of this much size can be transferred.

More importantly I want to know about the call recording function. Whether its available in Android phones as a native applicatoins or not? If its not available then can a application be written that can record all incoming and if possible outgoing calls as well.

View 3 Replies View Related

Android :: Blacklist Calls

Jul 14, 2010

Is there a blacklist app that allows me to simply reject (either by picking up and hanging up, or by saying the number is disconnected) numbers that I specify. I used an app called iblacklist on my iphone and it works wonders for this. I was wondering if there is something in the market that functions the same as this. iblacklist also removes the calls from the recent calls list, that would be useful but not very important.

View 13 Replies View Related

Android :: Way To Receive Calls Through Pc?

Apr 8, 2010

Does anyone know of an app (for hero) that would allow me to make and receive calls on my desktop when my phone is plugged in via usb? I have desktopSMS going and was wondering if there is something similar for calls. I have unlimited voice/text so i don't need anything to avoid that, my problem is that where i sit in the office i can't get a signal on the phone, but plugged in via usb my phone can sit on the window sill and get reception so it would be handy not to have to run across the room every time it rings! i tried searching the forums for this but on and pc are too short to search so you can imagine how many hits for "receive calls" there were!

View 13 Replies View Related

Android :: How To Block Calls

Jul 5, 2009

I want to block calls from few numbers, for that I want to write a app of my own. So what are the APIs which I should be using? Basically I want to get notified when a call comes, i want to compare numbers if it is what i want to block, i want to cut the call or mute it or if possible mute it and record it.

View 6 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved