When I type ImageView or AnimationDrawable I get a string of errors proclaiming:
AnimationDrawable cannot be resolved to a type.
line 14 Java Problem
I don't understand, do I need to create another class? Or do the AnimationDrawables just not go in the filename.java?
And if I do need to create another class, can you show me how?
...
Hi
I'm trying to develop an app that prevents a user from getting to a specified app without a password. The scenario is...
user clicks on "Email" app (for example)
my app detects launch of an app
my app confirms it is the "Email" app
my app opens a view over the top, asking for a password
user enters a password, if correct, my app dis...
Is there any way to display the empty message and the listview header at the same time? It seems that when i set the empty view and the list is empty, the header will not be displayed.
thx
Ben
...
Can I access android MediaProvider (Images & Videos) databases directly from my code rather then through a content provider ?
I'm planning to have my own Cursor implementation so inside it I want to access the media databases directly, possible or android does not allow it ?
...
Hi,
I'm developing for the Android platform.
My app creates a temp file with a simple call to:
FileOutputStream fos = openFileOutput("MY_TEMP.TXT",Mode);
It works fine because I can write to it and read it normally.
The problem is that when I exit from the app I want to delete this file. I used:
File f = new File(System.getProperty(...
I have an android app that stores data to the local storage. This is done just like in the tutorial on Google's site:
String FILENAME = "data.xml";
String string = "some content";
FileOutputStream fos = openFileOutput(FILENAME, Context.MODE_PRIVATE);
fos.write(string.getBytes());
fos.close();
However, whenever the device is powered ...
Hi,
I have a common class say for eg Class A which extends AsyncTask and has all the methods implemented i.e. onPreExecute, doinbackground and onPostExecute.
Now, there are other classes which want to use Class A object.
Say Class B uses class A in the below manner
A a = new A(context)
a.execute(url)
Then i fetch the result in get ...
Hi y'all!
I'm coding on the android right now, and I have an Activity which starts and stops a Service. However, related to this whole application will be a non-android java application which runs in the background alongside this app. I need this separate activity to be able to launch a notification, but I don't know how to do this. I c...
Hi all,
Got few questions related to Android.
How can i retrieve list of all the current activities (not packages/processes) running on the android system.
I am having an Service from there i need to send some data to an activity if it exists how?
how can i send linked list to an running Activity.
Thanks,
PP.
...
How can I setup an method to be called whenever Intent.ACTION_BATTERY_CHANGED is raised? Do I have to subclass BroadcastReciever? Or can I use a method to hook up the action to a method.
...
How can I get battery level and state (plugged in, discharging, charging, etc)? I researched the developer docs and I found a BatteryManager class. But it doesn't contain any methods, just constants. How do I even use it?
...
Hello, I'm adding tab icon via selector like this:
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@drawable/tab_cart_selected" android:state_selected="true" />
<item android:drawable="@drawable/tab_cart" />
</selector>
http://img844.images...
So I have created an android app and things are working alright.
In my main class I do a
new Game();
Now from the constructor of the game object I try and manipulate the screen, but it does not seem to do anything. Is it even possible?
public class Game extends Activity {
public void onCreate(Bundle savedInstanceState) {
...
Hii everybody ,
I am noob at android and need some help...
I am developing an app which requires me to write to an SQLiteDatabase in one activity and access it from another activity . I am facing a problem implementing this. Any suggestions/ideas as to how we can share the database across multiple activities ...?
...
Hi:
Thanks for reading my post.
How can I terminate TranslateAnimation before its reach the destination and immediately start a FrameAnimation at the position of which the TranslateAnimation has been terminate.
What I am trying to do is to apply a translate animation on textview, and make TextView more across the screen. I can click o...
So I've got this code (updated for solution).
@Override
public View getView(int position, View convertView, ViewGroup parent) {
...
final Direction d = directions.get(position);
if (d != null) {
TextView direction = (TextView) row.getTag(R.id.directionTextView);
TextView departure...
Hello All,
I would like to implement google walking/cycle directions into an Android app im creating but I'm struggling to get my head around how to do this. I've recognised that the most accepted way is to query google via http to retrieve a kml file, which is translated back into the android app. owever since I've been java/android pr...
On Android 2.2 Emulator, the "geo fix" command seems not to be working properly. The emulator responds "OK", and onLocationChanged() is properly called in my program. However, the Location object seems not to be complete--it registers latitude and longitude just fine, but it does not contain an altitude reading (hasAltitude() returns f...
Is there a way to directly inspect an SQLite3 database in Android via Eclipse or do I have to do this via the shell?
...
Hi, I'd be very thankful if someone would give me a hint on how to display a static ProgressBar (or any widget that displays a percentage in a bar format) within a ListView in an Android app.
Here's my code:
startManagingCursor(c);
String[] from = { "category", "amountPercentage" };
int[] to = { R.id.second_line, R.id.third_line_bar };...