Android :: Sending Android Intent With POJO Inside?
Oct 7, 2010
Is their a way to put a POJO inside the intent.putExtra? I have looked into the API's and it only seems to support of type string, int, double, boolean etc. But not a actual POJO / regular Java object.
View 1 Replies
May 20, 2009
- Hide quoted text -
View 2 Replies
View Related
Sep 12, 2010
I have code which has one activity which passes information to a second activity.
I can use this information to pass to a third activity with additional information from the result of the second activity.
I want to use gestures as a method of going back to a previous activity, but if I go back from the third to the second activity I need the information initially passed from the first to the second activity to still be present.
i.e.
First Acticity
what is Y?
answer y = 5
Second activity
User said Y = 5
what is X?
Third Activity
User said Y = 5
X = 6
Go back to Second activity but maintain the input of
User said Y = 5.
To do this I have used a bundle to pass the information between activities, but I can only access the info in the bundle from within a method within the class started by the intent.
The gesture controls are within another class, so I cannot access the bundle information from within this class as the getIntent command produces a not defined error.
What I need to do is to be able to pass the information from the bundle from the first activity to the gesture class so that I can pass it back when I go back using the gestures.
View 1 Replies
View Related
Nov 12, 2010
I want send LinkedHashMap to another Intent.
But I don't known what method for extras is allowable.
CODE:...................
View 1 Replies
View Related
Sep 30, 2009
From a service that's running, how do I send an event or an intent to an app widget that is just sitting their idle.
View 6 Replies
View Related
Jul 10, 2010
I want to send a broadcast from a new thread is start.
This is what i tried:
CODE:............
But ofcourse i need context..this won't work. How can i handle this.
View 1 Replies
View Related
Jul 25, 2009
I'm building a service that sends a broadcast intent when some value changes. The service sends the broadcast like this:
Intent broadcastIntent = new Intent(); broadcastIntent.setAction("nl.vu.contextframework.NEWREADING"); broadcastIntent.setData(Uri.parse("context://"+cer.getKey())); broadcastIntent.putExtra("reading",cer); broadcastIntent.addCategory("nl.vu.contextframework.CONTEXT"); sendBroadcast(broadcastIntent);
In some Activity (in a different process), I'm tryint to receive this broadcast as follows:
IntentFilter intentFilter = new IntentFilter();
intentFilter.addDataScheme("context");
intentFilter.addCategory(CATEGORY_CONTEXT);
registerReceiver(new BroadcastReceiver() {
public void onReceive(Context context, Intent intent) {
Log.d(TAG,"Received intent "+intent); }
}, intentFilter);
View 6 Replies
View Related
Feb 12, 2010
Is is possible to send an object to an Android Service through an Intent without actually binding to the service? Or maybe another way for the Service to access Objects...
View 2 Replies
View Related
Dec 2, 2009
I want to send an intent from a crash handler [ crash(String tag, Throwable t) in RuntimeInit.java) ] to an activity (stand alone appllication)
I tried to send it from above handler as follows..
CODE:................................
But i failed to send an intent to my application..
Can i send an intent to my application fro RuntimeInit.java handlers?
View 3 Replies
View Related
Aug 29, 2010
I have created an app that sends an email with a recording, When the intent is fired and email is chosen as the app to send the attachment, you can see that there is an attachement but the attachment is not delivered. code...
View 1 Replies
View Related
Jul 1, 2010
How can i access a content provider from a pojo? all ways i found depends on that my class extends Activity :-( api version 3
View 3 Replies
View Related
Sep 2, 2010
I am developing an Android application and I access a RESTfull web service that returns a JSON. This JSON I want to put it in POJOs but I think I am missing something as it doesn't work.
The JSON retuned is as follow:
CODE:.....
This is returned in response variable
CODE:.............
And now I try the following:
CODE:................
The error I get is:
CODE:.................
Here are the POJO objects
CODE:.......
To access the web service I use the class from: http://lukencode.com/2010/04/27/calling-web-services-in-android-using-httpclient/
Can't figure out how to continue. I found some subjects here but still didn't found a way around.
View 1 Replies
View Related
Oct 30, 2010
I've been a couple of days trying to solve this thing but I can'f figure it out.The problem is, simple activity, with simple layout, ScrollView -> LinearLayout -> and a lot of buttons inside the layout (within the scroll content). Everything works just fine but one tricky thing. When I click a button let's say at the top of the scroll content and inmediatelly I scroll down to the bottom of the content and I click other button there, nothing happens until I click a second time and all come to normal again.This can be reproduced anytime and it's code independent (i've tried more than 20 scenarios). I've not much experience in android yet but looks like the scroll listener stops the onclick listener or something like that.
View 1 Replies
View Related
Jul 7, 2009
So I've been extremely frustrated by this for a long time now.I've posted before, but can't seem to find a good solution. My goal is to have something pretty much exactly like the installed application details page in the Android Market.I need a list of items displayed along with other content above the list, and would like the content above to scroll up along with the list (exactly like the application details does for the "My Review" and other descriptive info).Due to responses to my previous posts, I came to believe that it really wasn't possible to do this with a ListView.So rather than using a ListView, I refactored my code to use a simple LinearLayout and add individual View items to the list, thinking I could just set each View as clickable and add an OnClickListener to each View in the LinearLayout.That's not working at all though, and now I'm getting even more frustrated.If someone can help me get the OnClickListener working, then I think it'll work, but I do need a separator for the LinearLayout.How do I add a separator like the one used for ListView to my LinearLayout?
View 12 Replies
View Related
Jun 24, 2010
I have a friend who is added to my Desire's contact list.
1. He is on my Facebook contact. (His facebook pic appears in my Desire contact list)
2. He is my Gmail contact as well.
3. He is added as a 'Phone Contact' as well.
I sent him a text few days ago but don't remember if it was using facebook or my phone (network provider sms) but now when I go in to 'Messages' and send him a message, I just can't figure out if I am sending him a message via Facebook or to his mobile number.
View 1 Replies
View Related
Oct 3, 2012
I'm wondering whether it would be possible to run ADB (Android Debug Bridge) inside an existing Android device. I saw this, but what I want is to be able to compile an ADB binary (plus any necessary libraries) for Android, put it on my sdcard, and run ADB commands from within a terminal emulator.
Secondly, I'm wondering whether, after installing ADB on one device (device #1), I could connect that device and another device (device #2) together, and use device #1 to perform ADB commands on device #2 (for example, rooting device #2 without needing a PC).
View 4 Replies
View Related
Aug 9, 2009
I have this strange problem with GPS. Inside the emulator,it displays the initial value but it does not update the value. This is what I am doing.I run my application and then go to DDMS,load the KML file and then click play.I am using android sdk:1.5_r3.This is the code I am using: package com.cameraExample..........
View 3 Replies
View Related
Oct 9, 2009
I want to run part of my app logic in a background service. However, much of the app uses JavaScript.Currently I run the JavaScript inside a WebView.Is it possible to have an invisible WebView while running inside a Service?If the answer is no, is there any way to run JavaScript inside a Service?
View 4 Replies
View Related
Oct 27, 2009
I ran into some trouble trying to use a Looper inside an AsyncTask (its doInBackground method). Everything works fine until new Tasks are being created by AsyncTask.sThreadFactory, but once I reach the AsyncTask.CORE_POOL_SIZE limit and AsyncTask begins to recycle the threads, sending messages to my looper (created inside doInBackground) results in a MessageQueue RuntimeException: "sending message to a Handler on a dead thread".
The code I tried was:
CODE:....................
View 4 Replies
View Related
Feb 23, 2010
I just created a webview activity, and I loaded a webside into it.Well, when the user starts to click on some button, my activity is gone and the default webbrowser-activity is opened.In this case my menuitems are lost. Is it possible to keep the browsing user inside my activity?
View 4 Replies
View Related
Aug 9, 2010
I am building many apps for Android and wish to have a menu button in the apps that basically opens a list of my other apps in the Android Market.
Is there a way to create an intent and have the Android market pop up with a search (of my company) in the market so users can buy other apps?
View 1 Replies
View Related
Jan 29, 2009
I am trying to run an ADB shell command from inside an android app using the JAVA's Runtime.getRunTime.exec API. I am getting an error "ERROR/ProcessManager(1041): Error running adb: Permission denied". Wanted to check if there is any permission that I need to request to get it working or that running the adb shell command would not be allowed from with in the Android app.
I am able to execute other linux commands like 'ls' from the android app though.
View 5 Replies
View Related
Nov 13, 2009
I have copied a file named hello(compiled form hello.c) in android data folder and using command like "adb shell datahello" in android machine terminal. and it give fine output.
Actual Question is that is there is any way that in button click listener, i initiate the same command like "adb shell datahello" (or any other appropriate way to execute adb shell commands) and gets its output in TextView.
View 2 Replies
View Related
Sep 17, 2010
I'm developing an android application where i want to add the volume control in Status Bar. Can i add a seek bar inside the Status Bar. I have worked with NotificationManager and I've found that adding animation is difficult in Notification bar.But can anyone please suggest if i can add a seek bar in my Status Bar(Notification bar).
View 1 Replies
View Related
May 27, 2010
I am trying to display STRING my car name is "abc" in textview.
It displays &qoute;abc&qoute; after running application.
I have tried decoding into " and then assigning it to TextView but it always convert " to &qoute;
View 2 Replies
View Related
Aug 21, 2009
I wanna put a "List" inside a TabActivity. by google and coder's guide, my work out "direction" is to create a "TabActivity" as MAIN and "ListActivity" then add it in the "TabHost" and turn out code something like (below) and fail:
CODE:.........
I know i may need to spend more time on the BOOK and google for android development, but i also feel that the resource for android is quit scattered and not detail. (i'm a developer of C# for a few years, and it's more easilier to search for information)
View 2 Replies
View Related
Oct 16, 2010
I've seen references to folks modifying the XML files contained inside the Android.jar.res.drawable folder and then copying them to their drawable folder for use in their project.
But I can't open these files, instead I get the following error.
Could not open the editor: org.eclipse.ui.PartInitException: Editor could not be initialized.
How do I open these files so I can use them?
View 2 Replies
View Related
Sep 1, 2010
I have a ViewFlipper that contains Layouts.
Is there a way I can hook up a Class to manage each layout seperately?
Kind of like setContentView(R.layout.main); but I'm not sure how to reference the 3 different layouts in code...
View 1 Replies
View Related
Sep 29, 2010
I am having a class that extends View. I have another class that extends activity and I want to add the first class to be loaded inside the activity class.
I tried the following code...
View 2 Replies
View Related
Apr 1, 2010
I was wondering how can I place a small button inside my EditText view (AutoCompleteTextView to be more specific), just like the iPhone has on its search box. http://img69.yfrog.com/img69/8931/keyboardv.png
View 2 Replies
View Related