android

android access listview row from another row

Suppose I have a listview with 3 rows. If the user clicks a button in row 1, it expands a menu (it's just a linear layout that's shown/hidden). If they then click on an item in row 2, I'd like to be able to collapse the menu in row 1. Is this possible? If so, how? ...

helloandroid tutorial error: request time failed

I am just starting out on android development and trying out the HelloAndroid tutorial. I have been stuck for a few days now. Initially, the first time I tried it, everything works perfectly and then I move on the second tutorial everything broke. So I'm trying to go back to the easiest and original tutorial and figure out what is happen...

how i can change in TabHost the text from horizontal אם vertical

in this line i want change the view of the text "Step1" to vertical mTabHost.addTab(mTabHost.newTabSpec("tab_test1").setIndicator("Step1").setContent(R.id.tabview1)); ...

Obtaining SurfaceView dimensions...

Hi everyone ! I think I might be about to ask a dummy question, but I'm still new with Android programming, and I couldn't (despite all my efforts) find my answer on Google. The thing is, I'm trying to develop a little game, with 2D Graphics. I want my "gaming board" to be at a specific position on my screen, so that I can display in-g...

Make Bluetooth on Android 2.1 discoverable indefinitely

Hello all. I'm working on a research project which involves Bluetooth and the Android OS. I need to make Bluetooth discoverable indefinitely in order for the project to continue. The Problem: Android limits discoverability to 300 seconds. I cannot ask the user every 300 seconds to turn discoverability back on as my application is d...

Back button on Android Phones

A couple questions about the back button (as seen on the emulator)... 1) Do all Android phones have the back button as a hard, tactile button? 2) If so, is it still recommended to put a back button in your software? 3) Is it possible to change the animation between activities when this back button is pressed? I would like it to be con...

android XML TableLayout issue: horizontal scroller going outside of right side of screen

I have a TableLayout with a tableRow and a horizontal scroll view in the 2nd column, but the right side always gets cut off. IF i have only 1 tableRow, it works, otherwise it goes past the visible area of the screen. To simply and isolate the problem heres an xml file with the guilty culprits. It seems basic but i have been super frustra...

Consolidating the number of activities in my Android app

In my application, I currently have several activities that consist of a TextView and a scrollbar. The only difference between them is the string that the TextView displays. Is there a way to consolidate all of these into one single activity, and depending on how/where the activity is started from, changes the TextView? Perhaps send the ...

Android ==> R.java project won't update R.java ????

my main class folder was named com.test, i changed it to com.myApplication, and now when i add objects to my layout my R.java won't get updated, all objects that i had before work fine, and they are in R.java, but anything new that i create won't get added to R.java Any idea how to resolve this problem? Thanks ...

Problem using ksoap2 with Android

I thought I'd have a crack at building an Android app having not done any Java for five years (I've been living in MS land). So my first project was supposed to be something easy. A simple login form that calls a WCF service that I already have from another project. So I got the whole thing set up OK in Eclipse and the app is running ...

Overriding DialogPreference's default BACK keypress behaviour

Hi... By default, when in DialogPreference you press BACK button, it mimics that you've pressed NegativeButton. I'd like to override that but can't find an easy way except to recreate DialogPreference from scratch (which at the moment seems like an overkill), because I'd like that PositiveButton SET something, NegativeButton to UNSET s...

Android Get Total App Memory (Heap + External Allocations)

In my android app, is there any way to get the total amount of memory my application is taking up, in the code. I'm using lots of large bitmaps, so it must include external allocations as well. I must, however, be able to get the number in the code, so that I can dynamically adjust to fit the budget I have. I also need a way to get the ...

Android: extending android.app.Application

Hi, I have a DBHandler class that will be used in several activities to do some crud operations. created a MyApp class (extends Application) to hold one instantiation of the DBHandler. My DBHandler class needs a Context to create the SQLiteOpenHelper to populate the db, etc. That's where the problem starts: in my MyApp constructor, ...

Refreshing a listview

I have a listview that's populated by rows that get their data from a web server. It all works totally fine except I want to have a refresh button to re-download the data. I'm getting the data through an asynctask (getting the data in doinbackground) and then setting the listadapter in onpostexecute. All I do to run the asynctask which s...

How to re-build the default "Launcher" application?

My goal is to modify the Launcher application and dynamic modify and change theme,I saw several 'home' apps as http://www.cyrket.com/p/android/com.stain46.taghome/ ,it looks like they took the default Home(Launcher) and modify it. The only thing I'm wondering is how they did that? usually what thing i need to modify in Launcher folder,...

Failed to getResource() utf file from package in Android

Hi, I have a custom java library which getResource() from an UTF-8 encoded text file in the package. keyWordPairs = new Hashtable<String, Vector<String>>(); try { File pinYinDatabase = new File(this.getClass().getClassLoader().getResource("myCustomLibrary/NewPinYin.utf").getFile()); BufferedReader br = new BufferedReader(new Fi...

Creating an ImageView with a certain style programatically

I want to do this programatically: <ImageView style="@style/TitleBarSeparator" /> Where TitleBarSeparator is: <style name="TitleBarSeparator"> <item name="android:layout_width">1px</item> <item name="android:layout_height">fill_parent</item> <item name="android:background">@color/title_separator</item> </style> I've tri...

android build source errors

i have ubuntu installed on the lenovo s10e netbook. i am not sure if this is related to the issue. i am new to source builds so i would appreciate some direction. i followed instructions on cyanogen's wiki (http://wiki.cyanogenmod.com/index.php/Building_from_source) i am stuck on the last step of 'Building CyanogenMod' after starting th...

Install Windows Phone 7 on Android MyTouch 3g?

I have a MyTouch 3G running Android, which has been rooted. I was wondering if it is possible to install Windows Phone 7 on this phone, or if it is even close to compatible. Thanks ...

Uploading images with FTP on Android

How can I upload images using FTP on Android? ...