Tag: eclipse

could not find the *.apk Error

[2011-06-22 23:55:09 – main] Android Launch! [2011-06-22 23:55:09 – main] adb is running normally. [2011-06-22 23:55:09 – main] Could not find main.apk! I am new to Android development and stuck in a very strange error. When I compile my Android application I get the above error. While before yesterday the application work nicely. Thanks in […]

How to disable back button pressed in android fragment class

I want to disable back button in fragment class. onBackpressed cannot work in fragment.how to disable back button?.. this is my simple code. public class Login extends Fragment { public View onCreateView(LayoutInflater inflater, ViewGroup container, ,Bundle savedInstanceState) { ViewGroup root = (ViewGroup) inflater.inflate(R.layout.login, null); return root; } public void onBackPressed() { } }

Eclipse+FindBugs – exclude filter files doesn't work

I’m using Windows and Eclipse 3.7 Classic with ADT plugin for Android development. I’ve just installed FindBugs and it have found a bug in auto-generated R.java class. I want to exclude this class from FindBugs checks. I’ve found that I can define exclude filters for FindBugs in xml file, so I’ve created a file D:\Projects\eclipse\FindBugsExculde.xml […]

Is there a way to print stack trace on demand?

I am looking for a way to get a stack trace when I am at a certain breakpoint. Is this possible? Ideally without having to crash the application and modifying the code. I tried playing with the Android debugger but couldn’t find anything very helpful. The reason is that sometimes I am not certain how […]

I'm having some trouble adding OpenCV to a new Android project

I have made modifications to several example OpenCV projects within Android, however I am having some issues with using OpenCV successfully in a new Android project. The documentation on using OpenCV with Android says to complete the following steps to add OpenCV to an Android project – ensure the Android project is in the same […]

Android – How to create clickable listview?

I want to make all my list items in the listview open up into a new page, so each listview item opens up onto a new black page that I can use. I don’t know how to implement this at all. I have searched for hours on end and can’t find an answer to my […]

Cannot run Android project in Eclipse despite no errors

When I try to run my Android project(which was working fine yesterday) I get the “Your project contains errors, please fix them before running your application” dialog. But my project has no errors. I’ve had this problem before, and the solution was always to Clean the project, but this time it isn’t helping. The red […]

Eclipse ADT – Unresolved inclusion jni.h

On my Windows platform, I have the latest version of adt bundle (20140321) and ndk (r9d) installed. The installation is as clean as it gets. The environment variables NDK_ROOT, PATH, etc. are all defined properly. The app I am working on has some C++ native code. The code builds fine both outside Eclipse as well […]

#if in java, like in c preprocessors

Possible Duplicate: How to mark java code such that it’s not compiled In c, we can prevent compilation of block code like this : #if 0 //code here #endif So even if code block is error prone the code compiles, I want the same thing in Java, So that I can skip that part of […]

getOutputMediaFile(int) is undefined for the type new Camera.PictureCallback(){} error confusing me

I cannot figure out why this is occurring. It is probably a silly mistake that I cannot identify. Again the error is: getOutputMediaFile(int) is undefined for the type new Camera.PictureCallback(){} my code: public static final int MEDIA_TYPE_IMAGE = 1; private PictureCallback mPicture = new PictureCallback() { public void onPictureTaken(byte[] data, Camera camera) { File pictureFile […]

Android Babe is a Google Android Fan, All about Android Phones, Android Wear, Android Dev and Android Games Apps and so on.