android

Android Converting .NET Path.Combine to java?

We are converting apps to Android from .NET Is there a Java equivalent of the .NET Path.Combine() function? Currently we check the / on each folder etc before building paths. ...

How can I parse a namespace using the SAX parser?

Hello, Using a twitter search URL ie. http://search.twitter.com/search.rss?q=android returns CSS that has an item that looks like: <item> <title>@UberTwiter still waiting for @ubertwitter android app!!!</title> <link>http://twitter.com/meals69/statuses/21158076391&lt;/link&gt; <description>still waiting for an app!...

retrieve contact's nickname, part 2

Hello, A few weeks ago I asked exactly the same question here. At first, I thought the answers solved my problem, but they didn't. I just didn't notice that I wasn't able to solve my problem with those answers. However, what I've got now is: final Cursor phoneCursor = context.getContentResolver().query(Uri.withAppendedPath(PhoneLookup...

On the fly calculation of Fourier transformation in Java

I want to write a program in Java that uses fast Fourier transformation. The program reads data every 5 milliseconds seconds from sensors and is supposed to do something with the data every 200 milliseconds based on the data from the last five seconds. Is there a good library in Java that provides a way to do Fourier transformation with...

ProgressDialog doesn't appear.

I have the following in my Activity that I use to download a users films in their LoveFilm queue, but the ProgressDialog never appears. public class MyListActivity extends Activity { SharedPreferences prefs; ProgressDialog m_progressDialog; Thread listThread; User user; private Runnable threadProc_initializeQueue = ...

How do I add a button to my list when I'm forced to use simple_list_item_1?

I have a list, and I want 'Next' and 'Previous' buttons at the bottom of the list. I've tried to make the ListAdapter for the list something other than simple_list_item_1, but Android won't let me. I keep getting '... can't be resolved'. Now, simple_list_item_1 is some kind of magical unicorn that is impossible to find, so I can't chang...

How to - Comments in layout xml

I would to enter in some comments into the layout XML files, how would I do that? thanks, Dean ...

Simple simple 2D graphics in a view

What is the simplest way to draw pixels, lines and circles on a View? I want to move a cross cursor around, so nothing particularly intensive. I thought I could extend SurfaceView and add it to an XML and it would just work, but it just appears black, however, when I look at the layout view of localmap.xml in eclipse, the graphics appea...

Communicating between two smartphones without using a Cellular Tower - Peer to Peer

Lets say I have 2 mobile phones which are 50 meters away from each other and I would like to send a very small packet of data from mobile-A to mobile-B, without using any communication to cellular tower. To make it simpler, I would like to build an app which implements a Peer to Peer connection for 2 mobiles in the same radius (in the s...

Android ==> Service question ???

I have a service running on my android application, the service is a socket class that has to run through the whole application, i create it when my first activity loads. How can i get an instance of this socket class so that i can call a function in this class. For example //how can i get an instance of the running service? MyService s...

How to connect the android phone on Ubuntu 10.04

Hi All, I tried to test my application on my android phone, but the it can't be able to detect the device compatibility. The debug mode on phone is enabled. My phone: Motorola. My ubuntu: 10.04. IDE: Eclipse. I even tried to add the following line: SUBSYSTEMS==”usb”, ATTRS{idVendor}==”22b8″, ATTRS{idProduct} ==”41db”, MODE=”0600" t...

Add a List to my layout

I want to create a layout like this: On the top a TextView, after it a scrollable list of words, in the bottom two buttons. But in order to create a scrollable list I think I must use ListActivity, but I want to create an Activity so the only scrollable part is the list and the TextView and buttons are fixed. How can I do this? ...

Update database on CheckBox click in Android?

Here is my custom ListView item. The problem is that I want it to update my database whenever it is clicked. And to do that I need to get the row id of the ListItem of the CheckBox that was clicked. Also could you please post a code sample. ...

Why won't a Android 1.5 app run on Android 2.2 phone or emulator?

I'm developing an Android application using Android 1.5. I'm using an older version of the SDK because I'm building it to run on a single G1 phone. I've been using a 2.1 emulator without any problems, but when I tried taking a look on my Nexus One (2.2), the application immediately stopped responding. I then tried a 2.2 emulator with th...

Unable to open both main.xml files from layout & layout-land at the same time?

While developing for Android, I am unable to open more than one main.xml file in an Eclipse editor at a time. Each time I open one, it simply replaces the editor (tab) of the first main.xml with the new one, instead of opening a new tab - even if the contents of the existing tab were unsaved! Even stranger, I can open multiple main.xml...

Click TextView and Changing the Text

I am making my TextView clickable and want the text to change as I click on it. So the TextView starts out saying "Al" and when its clicked I want it to change to say, let just say "Hi" for now. And then also go back when clicked again. Here is my code. package table.periodic; import android.app.Activity; import android.conten...

Timer in Android not working

Hello, I'm trying to get an alert box to show up 5 seconds after my application starts on Android. But it's not working and I don't know why. Here is the code: package com.example.helloandroid; import java.util.Timer; import java.util.TimerTask; import android.app.Activity; import android.app.AlertDialog; import android.content.Dial...

How to implement login functionality in an Android app safely?

Firstly, no OAuth or other things supported in the server-side, just a normal username-password database querying. I want to implement an android client for the web site. My questions are: How to login safely? with HTTPS? How to store user login information safely in the phone to make user login without any input in the next time. If ...

Android Kill all Open ProgressDialogs?

How would I ask the current activity for a list of any ProgressDialog's visible so that I can call their Hide() method? ...

what tools to use to encode ogg files for Android 2.2 (some work in 2.1 but not 2.2 )

After the upgrade to Android 2.2 os my application Myan Calendar Countdown 2012 is broken It has been on the Android Market for 5 months and working fine. now the movie file just shows black and some sound files do not play Here are some files that no longer play http://www.roguetreasure.com/downloads/button25.ogg and http://www.roguet...