android

How to adjust 3 ImageViews in a LinearLayout

I defined a LinearLayout: <LinearLayout android:id="@+id/top_menu" android:layout_width="fill_parent" android:orientation="horizontal" android:background="@drawable/backrepeat" android:layout_height="wrap_content" > <ImageView android:id="@+id/topLeft" android:layout_height="wrap_content" ...

How can I get certain text from wikipedia?

Take this for example: http://en.wikipedia.org/wiki/United_States_Bill_of_Rights Under the "Amendments" section, I want to get what each bullet point says, and display them in a nice list in an android application. I know there's a wikimedia api, but I have absolutely no idea how to use it, and from what I understand of it, you can get ...

could not create a project

hi, i have installed android sdk for windows and finished installation. i am using eclipse and also installed adt plug-in. but i could not create a new project by doing like this on eclipse: goto window -> android sdk and avd manager -> new because the window target option is disabled and hence could not create the application. but,i ...

Android Library is not working.

Nothing too exotic. I have classes in a library project, which is set to "Is Library". The target application project uses this library under the Project Properties/Android section. The project is set to version 2.1-Update (api 7). None of the classes from the library are visible in the target project. i.e. import statements referencin...

android: cant see log output

hello, i try to log some text using Log.v or Log.e but i cant see the text anywhere in the eclipse console. what am i missing? thanks! ...

Can I force a specific layout orientation, but have an opposite keyboard orientation? Android

I understand how to force a specific orientation per activity in the android manifest. I would like to know if it is possible to allow the keyboard to change orientation even though the activity(the layout really) must remain unchanged. ...

[android] Why would only 50% of my drawables be drawn?

I have tried to create a simple application that draws a png graphic where the screen is touched. The problem that I have is that only every other instance of the graphic I add is actually rendered. Each time I add a new instance, the pattern alternates. I always get only 50% of the graphics rendered. I am using android level 3 on HTC H...

Is there a way to use setOnClickListener with an Android Spinner?

The java.lang.RuntimeException is "Don't call setOnClickListener for an AdapterView. You probably want setOnItemClickListener instead," but that is not correct. I am using setOnItemClickListener to do some stuff based on the new selection, but I also need to do some stuff before the user changes the selection. Specifically, I am collecti...

Server Error in '/MobileAdmin' Application.

I have recently hooked up an Android device to Exchange 2003 via ActiceSync, and the MobileAdmin application (https://server/mobileadmin) crashes when I lookup a mailbox that is associated with an ActiveSync device. When I look up a mailbox that is not associated with a mailbox, it simply replies "No devices were found for this mailbox."...

Can an android phone pause wifi scan requests?

Hello people! I wrote an android application to request a scan for available wifi signals around, using the WifiManager, then dump the results to a file. The program works fine, but this weird bug occurs. Initially I was requesting a scan every 30 seconds, and everything worked fine. I then tried to request a scan every two seconds, I ...

onupdate() is not calling while using analog clock widget.

I have used analogclock widget in XML while running the program onUpdate is not called. Is there any way to get control for drawing a bitmap/text on the widget.? Can I update the widget in onReceive()? My code goes like this... public class ClockWidget extends AppWidgetProvider { @Override public void onUpdate(Context context, Ap...

How to add an icon before every ListView item text in an Android Application?

How can I add an icon before every ListView item text in an Android application? Here is the current list_item xml that is called to populate the list: <?xml version="1.0" encoding="utf-8"?> <TextView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@android:id/text1" android:layout_width="fill_parent" ...

[android] How does the FingerPaint activity from APIDemos sample save its state?

The FingerPaint activity in the standard APIDemos project, that comes with the android sdk, allows the user to use the touch screen to draw on the screen. If I run this activity, touch the screen a bit, and then hit the home key, that activity looses focus and is paused and stopped. When I then switch back to the APIDemos application, I...

ActivityGroup and SearchDialog

So I have a default searchable Activity in my app, and if I press the search button in simples activities it works. But when I'm in a tab where the content is an ActivityGroup, and not an Activity, the app crashes. 08-19 17:18:23.438: ERROR/AndroidRuntime(9078): Uncaught handler: thread main exiting due to uncaught exception 08-19 17:18...

dx.jar error code 2 android dev

I have working project,in Intellij IDEA,when i want add a new class and rebuild project,i have an error: trouble processing: class name (az/mecid/atodo/rtm/api/data/RtmData) does not match path (/home/mega/IdeaProjects/atodo/out/production/atodo/az/mecid/atodo/rtm/api/data/RtmData.class) ...while parsing /home/mega/IdeaProjects/atodo/ou...

android - pass string from activity to layout?

How can I pass a string from an activity to a layout? I can pass arrays from an activity to a layout with the following activity code ListView remedyList = (ListView) findViewById(R.id.ListView_Symptom); String remedyArray[] = new String[30]; ArrayAdapter<String> adapt = new ArrayAdapter<String>(this, R.layout.menu_item, rem...

clearing contents of a RelativeLayout programmatically - android java

I am dynamically adding ImageViews to a RelativeLayout depending on user input. I have also created a button that when pressed, should clear all of the content of that RelativeLayout (remove all children). I was hoping for a .clear() method, but no such luck. can someone point me in the right direction here? RelativeLayout rel = (Rel...

Difference between Android Service and Content Provider

I am developing an app and get confused about the idea of Service and Content Provider in Android. In practice, what will be the difference between them? Content Provider is a facade and it defines a way to share data among applications. You many attach a local database to your app or create Content Provider mapped to a universal databa...

Where can I find a good example of FastScrollView?

I have a long "cities" list. I was looking for an equivalent to sectionIndexTitlesForTableView in the iphone world. It provides a way to "jump" to a particular point in long lists without having to scroll through all the elements. I think FastScrollView implements this but it's not part of the API and I can't find any documentation o...

How can I have a portrait-oriented menu in my lanscape-oriented view in Android?

How can I have a portrait-oriented menu in my lanscape-oriented view in Android?Hi, I'm building an application with some items that must be landscape-oriented. Everything else (menu, view for editing the item, list of item...) should change orientation according to the orientation of the device. To do that I set android:screenOrientati...