android

What is the difference between android:layout_width and android:width

I do not know the difference between these two attributes and for the height also. Take a TextView for example, what would happen if I set its layout_width to wrap_content and set its width to 50 dip? ...

Android Programming - Send mail

I'm using the following piece of code in Android to send a mail: Intent emailIntent = new Intent(Intent.ACTION_SEND); emailIntent.setType("text/html"); emailIntent.putExtra(android.content.Intent.EXTRA_EMAIL,sendTo ); emailIntent.putExtra(android.content.Intent.EXTRA_SUBJECT, "test" ); emailIntent.putExtra(android.content.Intent.E...

Android camera out of memory exception

Hello! I have a strange problem on my htc hero. When launching camera, i get out of memory exception. After that, if i launch any other application that uses camera, they also crash(when trying to use camera function). I call camera.release and camera.stoppreview in surfacedestroyed function, but that doesnt help. What is the right wa...

byte[] to image android

Hi everybody, My issue is as follows : I have stored a few pictures into the sqlite database, using the blob format, which seems to work ok. now i want to get my pictures out of the DB and put then back into images... to complicate the matter, their format is variable (png, jpg, maybe something else, im not sure) Is there a way of doing...

android activity block user interactions

How can I temporarily block all user interactions with the views of an activity ? (Other than calling the setEnabled method on each view) ...

How to customise the TextView inside a Spinner?

I have a Spinner with an ArrayAdapter that feeds Values into it. The layout for this views looks something like this: <TextView android:text="Household Income: " android:layout_width="wrap_content" android:layout_height="fill_parent" android:gravity="center_vertical" /> <Spinn...

AVD Screen orientation not changing with CTRL+F11 or CTRL+F12

I run my app in the AVD emulator using eclipse but I'm unable to change the screen orientation in the AVD (Android 2.0 platform on the emulator). When I press CONTROL+F11 or CONTROL+F12 on the keyboard, nothing happens. No messages are generated in the adb debuglog/logcat either when I press either hotkey. According to http://develop...

Android DownloadManager - few questions

I have a few questions about the Android browser download manager . Does it support multiple downloads at the same time? From the code it looks like it does. What's advantage of using HTTPRequest over URL/URLConnection to download files? 3.The download manager opens and closes connection for each download. Is it the right thing to do...

Archos 5 IT audio paths... (Android)

I want to import all songs (on the Archos 5 IT) into an array in my app? How can I do this? -What is the file path? -How do I get an array? Please help... Thanks alot, James ...

Preference screen xml

Hi , I have a main view that presents to the user the settings he/she can modify for an application . It's xml is something like this : <PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android" android:key="root_preferencescreen"> <PreferenceScreen android:key="general_sett" android:title="general...

Any way to change the color of a radio button?

I'm working on an android form with a radio group containing a set of radio buttons. From what I can tell there is no way to set the color a radio button highlights when you select it. It seems to always default to some bright green color. Is this something that is editable or no? Thanks ...

Why doesnt R.raw.'songname' not work on android devices?

I have some media (Audio tracks) on an app... With file path 'R.raw.test' I use some code to get it into a mediaplayer... MediaPlayer.create(Textbox.this, R.raw.fly); And it works PERFECTLY on the Android Emulator... (Plays track on click of button) Can someone explain why, when I put it on my Archos (5 IT) it doesnt work at all? ...

Parse Exception: At line 1, column 0: no element found

Hi everyone, I have a weird issue. I receive the following error that causes a force-close: org.apache.harmony.xml.ExpatParser$ParseException: At line 1, column 0: no element found at org.apache.harmony.xml.ExpatParser.parseFragment(ExpatParser.java:508) at org.apache.harmony.xml.ExpatParser.parseDocument(ExpatParser.java:467) ...

Can an application's Service ever run in a different process?

If an application begins a Service via bindService or startService, will this Service object ever run from a process different from that of the application? I ask because many Android example projects begin a service and communicate to them using IPC which seems wholly unnecessary considering that, according to the Android Service docum...

Android Set ImageButton as Toggle

How can I have an imagebutton stay in the 'pressed' state when it is clicked? Basically I just want the background to be the depressed background, but I can't figure out how to set it. At the moment, I've just copied the selected button background into my res folder, but when I set it as the background, it becomes blurry (since the origi...

Android - Invoke activity from within jar

Hi All, I have a jar that consists of a class that extends Activity and performs some activity on onCreate. I want to import this jar into my Android app and start the activity. How can I go about this? Thanks George ...

Android Xperia X10 SoundPool

Hi All, I have had some reports from users of my android app that there is no sound being played on the X10. I'm a bit confused as it works on all other phones that I have tried, Neus One, Hero, Droid. I'm using the SoundPool class to play sounds, has anybody else had similar issues with the X10? Thanks, Gaz ...

Scheduling a recurring alarm/event

I have a class that extends Application. In the class I make a call to AlarmManager and pass in an intent. As scheduled my EventReceiver class, that extends BroadcastReceiver, processes the call in the onReceive method. How would I call the intent again from the onReceive method to schedule another event? ...

Do i need a real Android device to develop an Android software for the marketplace?

From your experience, to develop an Android software for the marketplace, do i need a real Android device to test my applications or emulator is enough? ...

Call webservice from Android using KSoap simply returning "error" string

I'm trying to use ksoap to call a simple webservice. I followed this video to try to get started. When I call "getResponse()" on the envelope I just get the string "Error". There's no exceptions thrown or any other detail. I've successfully connected to a simple webservice I just setup on my local machine. Could this potentially be ...