Android :: Prepare The UI From The Webservice

Aug 30, 2010

Playing around with the UI and SQLLite for a while and it looks pretty good to me . We have a requirement that for the App that all the questions would be coming from the server through REST / Web service which would be displayed on the App..

say for e.g if there are 4 questions
1) Enter your Name -- Text Box
2) Did you sleep well last night -- YES / NO
3) How many hours did you sleep - Text Box
4) How did you hear about us -- Drop down

So the requirement is that the Questions would be displayed on the App after doing a SYNC with the server during the SYNC with the server the Questions would be downloaded from the SERVER through REST / Web service..if the phone is not connected then pull the questions from the Database...

These questions are simple questions and they change quite often and we have a similar app which is there for iphone which does this ....

Android :: prepare the UI from the webservice


Android :: Looper - Prepare

Sep 27, 2010

I'm trying to initialize OpenFeint in my game like this:

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

Result: 1. OpenFeint initialization sometimes take so song(network actions?). It blocks the main thread. 2. My application remains in onCreate() for too long. 3. My Dev Phone One display ANR(application not responding) dialog prompting me to choose between 'Force Close' and 'Wait' 4. Soon after that, OpenFeint has done its things and my game shows up behind the dialog. 5. Now pressing 'Wait' will dismiss the ANR dialog and I can continue my game properly.

But obviously we don't want ANR dialog. So now I put it in a Thread like this:

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

---------------------------------------------------------------------------­-- Result: Problem solved. Everything seems to run fine now.

I put Looper.prepare() there because my game will crash if I don't. The log message told me to put it there. I put Looper.loop(); there because OpenFeint will not initialize at all if I don't. I've read the doc about Looper but honestly I don't understand what the doc says.

Question 1. The doc also tell me this: ------------------------------------------------- public static final void loop ()

Since: API Level 1 Run the message queue in this thread. Be sure to call quit() to end the loop. -------------------------------------------------- Can anyone explain when & where should I call quit()?

Question 2 What will happen if I don't call Looper.quit()?

Question 3 Let me ask this straight. Am I taking the correct approach? Is there some kind of loop running alongside my game all the time if I do this?

View 5 Replies View Related

Android :: Camera Prepare Fails

Sep 10, 2009

I'm trying to build a simple video recorder for an Android device and I've had limited success and mixed results. It worked once, but now, without changing anything, I'm getting a "Camera is not available" error followed by "prepare failed -2147483648" error.

View 1 Replies View Related

Android :: Prepare Failed In MediaRecorder / Way To Fix

Jul 3, 2009

I am trying to develop an application with Android 1.5(cupcake_r1) for a week but always get an error reported in prepare of MediaRecorder. Can anybody help me to figure out the problem I got in the code below:

PS. In order to figure out the problem, I suppressed the audio recording, and the SDcard is installed in the phone.code...

View 3 Replies View Related

Android :: Api I Can Use To Prepare VCard In Droid?

May 18, 2010

I am preparing a contacts application and would like to support the VCard export. Can anyone tell me if there is any API I can use to create a VCard.

View 4 Replies View Related

Android :: How To Use Other External Cursor / Prepare By SQL Database?

Sep 21, 2009

In the API Demo, there is example on using Simple Cursor Adapter. However, it is using the MediaS tore cursor. Is there any method so that I can use other external cursor prepare by SQL database. I don't know what should I input to the from String.

View 2 Replies View Related

Android :: Media Recorder Prepare Causes Segfault

Mar 28, 2010

I have a situation where my MediaRecorder instance causes a segfault. I'm working with a HTC Hero, Android 1.5+APIs. In the log i see (after the segfault announcement) a register dump and then a numbered list #00 libmedia_jni.so to #18 linker, then a stack trace. My Eclipse won't let me copy the log buffer, but I've done three screen captures that sum it up. If you have time to examine, send me a direct e-mail.<pre><code> if (mRecorder == null) mRecorder = new MediaRecorder(); mRecorder.setAudioSource(MediaRecorder.AudioSource.MIC); mRecorder.setVideoSource(MediaRecorder.VideoSource.CAMERA); mRecorder.setOutputFormat(MediaRecorder.OutputFormat.MPEG_4); mRecorder.setAudioEncoder(MediaRecorder.AudioEncoder.AMR_NB); mRecorder.setVideoEncoder(MediaRecorder.VideoEncoder.MPEG_4_SP);// mRecorder.setVideoSize(640, 480); // mRecorder.setVideoFrameRate(20); mRecorder.setPreviewDisplay(surfaceHolder.getSurface()); mRecorder.prepare();mRecorder.start(); </code></pre> I've tried other variants, including H263 and 3gp. What else can I do to debug this? Everythin g seems fine up to prepare(). I tried adding the onErrorListener, but it seems to interfere with the MediaPlayer's onErrorListener. I'm using a 4-second beep-count to prepare for auto triggering of the camera, and when I enable the error handler for the MR everything in my handler state machines goes awry.

View 4 Replies View Related

Motorola Droid :: How To Prepare For Android Update 2.2 (Froyo)?

May 22, 2010

Since no one knows when the update is going to come to the Droid. Could be tomorrow or in three months. Its all up in the air. It could happen anytime. Anyways, What do you need to do?

Have a battery near full all the time?
Backup your Aps?
Backup contacts?

Since I am assuming you can get the update without warning, I just wanted to know what steps to take, so I can have no problems with an OTA update.

View 11 Replies View Related

Android :: Need To Prepare KML File For Droid Emulator Control

Jan 21, 2010

I am trying to test my application with location information.
You know the Emulator Control has an ability to load from KML file. (Eclipse -> DDMS -> Emulator Control -> Location Controls -> KML -> Load KML...)
I've prepared KML file using Google earth application with its "Add path". Then saved it by .kml extension and load it on the Eclipse. Eclipse didn't load this KML file.

How to prepare KML file for Android Emulator Control?

View 1 Replies View Related

Android :: MediaPlayer.setDataSource - Fd - Cause IOException: Prepare Failed - Status - 0x1

Aug 6, 2009

What is the preferred way of reusing a MediaPlayer when using resources? My try looks a bit ... too complicated... so maybe I should be happy to see that it didn't work. (I run the Android 1.5 SDK and emulator.)

According to this thread my problem may be a permission problem. http://groups.google.se/group/android-developers/browse_thread/thread...

I get the same error. But in my case it only occurs when I use FileDescriptor!?! The use case differs however, because I use a resource stored in the bundle. I have s0.mp3 safely stored in the project /res/raw and it successfully plays when I use SoundPool or MediaPlayer.create. And the log print tells me I referenced the correct file and stay safely in my package.

I'm sure my way of getting the fd out from a package resource is the problem, I didn't find any other way... But why didn't setDataSource throw the exception instead of a printout? And why on earth is the same resource happily played one way but not the other? Seems like a design flaw rather than a security raise. Should I look in the MediaPlayer.create code to see how they get around the problem or can you help me understand how it works?

This is a test code snippet: (from onCreate of a simple Activity)

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

And the error:

CODE;..............

View 2 Replies View Related

Android :: MediaRecorder Error: Java.io.IOException: Prepare Failed

Sep 8, 2009

I am trying to write a sample program to record the video (say camcorder application). When i run my program using the emulator (I have android-sdk- windows-1.5_r3) I see java.io.IOException: prepare failed. error in logcat output.

Further I can see that I have came across this error when i call MediaRecorder.prepare() from CamcorderActivity.surfaceCreated() But I am surprised to see that activity got launched and I am seeing the camera preview! Again the preview is seen only in half of the screen! Its weird!!!

Further when i do recorder.start() to record the video I get java.lang.IllegalStateException. Yes this is obvious since the prepare () has failed. But the question is why prepare() has failed ?

Here is my code ... package com.example;

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

View 2 Replies View Related

Android :: Can't Create Handler Inside Thread That Has Not Called Looper.prepare

Oct 6, 2010

What does the following exception mean? And how can I fix it?
This is the code:Toast toast = Toast.makeText(mContext, 'Somthing', Toast.LENGTH_SHORT);
This is the exception:
D/VVM ( 684): java.lang.RuntimeException: Can't create handler inside thread that has not called Looper.prepare()
D/VVM ( 684): at android.os.Handler.(Handler.java:121)
D/VVM ( 684): at android.widget.Toast.(Toast.java:68)
D/VVM ( 684): at android.widget.Toast.makeText(Toast.java:231)

View 1 Replies View Related

HTC Aria :: AT&T / ROM To Prepare For OTA Firmware Updates

Sep 16, 2010

Looker, lookie, new Aria ROM to allow OTA firmware updates, plus two other bug fixes. I think they are gearing up for Android 2.2, HTC Mobile Phone Support - HTC Aria? (AT&T) - Downloads

View 1 Replies View Related

HTC Incredible :: Prepare Sd Card And Phone Keeps Shutting Off

May 8, 2010

i have no idea why it is turning off i got the phone yesterday. would it be because it is trying to prepare my sd card?it started when i put the card in.

View 4 Replies View Related

Samsung Vibrant :: Want To Prepare Phone To Be Returned To Tmobile / Fix It?

Sep 21, 2010

I've been having an issue with my headphone jack and finally called into Tmobile tech support.
They are going to be sending a replacement phone, so I would like some help on how I can get my current phone ready to be sent back to them.

Currently it is rooted stock 2.1 and has ryanza lag fix applied.
Most of my files are on the SD.

I know I need to unroot, how would I proceed to do that and would unrooting get rid of the lag fix?

View 16 Replies View Related

Android :: Calling .net Webservice From App

Jan 11, 2010

Best way of calling an asp.net web service from my android app. I am planning on using ksoap2 ? Is this a good route to go, or is that the only way to go? Do I have other options? What is the most efficient way if there are other options?

View 5 Replies View Related

Android :: WSDL Webservice

Jun 5, 2010

I have a case in which i have created a web service in java. I have .wsdl file of this web service.

Now i want to send request and get response i.e. communicate with this web service using the .wsdl file. I tried searching a lot but did not find any satisfactory post or code sample to do that. Whatever i came across is of .net i.e. .asmx file.

View 2 Replies View Related

Android :: Webservice With BraoadCastReciever

Oct 11, 2010

I have to call httpClient Within broadCastReciver ,but I got the following error

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

View 1 Replies View Related

Android :: Client For JAX-RPC WebService

Aug 30, 2009

Trying to write a client in Android for JAX-RPC Webservices developed in JAVA.

Is this possible and please suggest any examples for this.

View 2 Replies View Related

Android :: Call .NET Webservice

Jun 7, 2010

We have a SOAP webservice that is used for an iPhone application, but it is possible that we need an Android specific version or a proxy of the service, so we have the option to go with either SOAP or JSON. I have a few concerns about both methods:

SOAP solution:

Is it possible to generate java source code from a WSDL file, if so, will it include some kind of proxy
class to invoke the webservice and will it work in the Android environment at all? Google has not provided any SOAP library in Android, so i need to use 3rd party, What about the performance/overhead with parsing and transmitting SOAP xml over the wire versus the JSON solution?

JSON solution:

There is a few classes in the Android sdk that will let me parse JSON, but does it support generic
parsing, like if I want the result to be parsed as a complex type? Or would I need to implement that
myself? I have read about 2 libraries before here on Stackoverflow, GSON an Jackson. What is the difference performance and usability (from a developers perspective) wise? Do you have any experince with either of those libraries?

View 2 Replies View Related

Android :: Example Of Rest Webservice

Sep 30, 2010

can anybody give example of rest webservice in android

View 1 Replies View Related

Android :: Webservice SOAP

Oct 15, 2010

I'm calling soap webservice in android app. its working fine and getting the response in SOAP object. I don't know what to do after that. I'm searching for tutorial but I didnt find any. I'm really very fed up. I need to parse the reponse.

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

View 2 Replies View Related

Android :: Connecting To A Webservice ?

Nov 16, 2010

I have searched SO for anser to my question which is "invocking a remote webservice from a j2me application". All the tutorials refer to implementing it as a MIDLET. But I am not using a midlet. Can anyone please tell me if it is possible to invoke a webservice in plain j2me application, which is as basic as a hello world?

I am coding for android. My code starts with somethig like

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

I want to know if a webservice can be invoked from this kind of program?

View 1 Replies View Related

Android :: Android - Can't Handler Inside Thread Not Called Looper Prepare

Sep 30, 2010

I am getting reports of 'Can't create handler inside thread that has not called Looper.prepare()' once I added ScoreNinja to my Android app, and released it to the market. It seems that it isn't happening all the time as the ScoreNinja highscore has lots of entries from users. I have looked on the web for help but there are no clear directions on what to do. I have used the ScoreNinja code exactly as shown on the scoreninja website. BTW If anyone is having problems with ScoreNinja only displaying one score, check to see if the launchmode is not set to 'singleinstance' in your manifest. This fixed it for me!

View 6 Replies View Related

Android :: Client To Invoke The Webservice

Dec 2, 2009

I need to call a webservice from Android,the webservcie was created by Axis.I make a simple client to invoke the webservice on computer,get right response.But when I move the project to Android.there is one error:java.rmi; I dont's know where use this library.

View 2 Replies View Related

Android :: Google Api Ajax Webservice

Nov 23, 2010

I have created json parser to parse the data from this http://ajax.googleapis.com/ajax/services/search/local?v=1.0&sll=48.85...

I want to parse this data and wanna show in list view in android.

View 3 Replies View Related

Android :: Accessing A SOAP WebService

Feb 13, 2010

I have not found any convinient way to create something like a jaxws wrapperclass for an existing Soap Webservice - like in full Java. Jaxws is unfortunately not avaliable in the sdk. Is there any was to do this without using any external libs? Are there any external libs at all yet?

View 3 Replies View Related

Android :: How To Call A .NET Webservice Using KSOAP2

Jun 27, 2009

I have a problem while calling the webservice,i have a .NET web service in the server and i am using KSOAP2(ksoap2-j2se-full-2.1.2) in android.While running the program i got an runtime Exception
like "org.ksoap2.serialization.SoapPrimitive".

I dont know what to do.Here is my code.

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

View 6 Replies View Related

Android :: App Connecting To A Webservice - Not Working

Sep 12, 2010

Iam trying to connect my App to a WCF service that I created in asp.net.

The service runs on my localmachine: http://localhost:8080/Service.svc/

But for some reasons my Android can not connect to this http-adress.

This is the error: 09-12 14:50:44.540: WARN/System.err(593): org.apache.http.conn.HttpHostConnectException: Connection to http://127.0.0.1:8080 refused

This is the method in wcf, Iam trying to return a collection with some values.

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

And this is how the connection in the android looks like:

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

View 1 Replies View Related

Android :: How To Call A PHP Webservice Using KSOAP2?

Sep 16, 2010

"How to call a PHP Webservice from Android using KSOAP2?"

View 1 Replies View Related







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