Skip to main content

Posts

Showing posts from August, 2013

Screen Resolutions & Densities

Finally created a structure which handle layouts and icon for multiple screen. Android generalises device displays into categories based on two parameters: Screen size, the physical size of the display (measured diagonally) Screen density, the physical pixel density of the display (in pixels-per-inch, or ppi)` Screen size Android defines four generalised screen sizes: Qualifier Size small ~ 3 inches ( approx ) normal ~ 4 inches ( approx ) large Exceeds 4 inches xlarge Exceeds 7 inches Most phones are classified as small or normal (roughly 3 to 4 inches diagonally) A small tablet like the Samsung Galaxy Tab is classified as large (larger than 4 inches) Extra-large applies to large devices, for example large tablets Android defines four generalised screen densities: Qualifier Description Nominal value ldpi low density 120 ppi mdpi

Failed to install *.apk on device '*': Local path doesn't exist OR com.android.ddmlib.SyncException: Local path doesn't exist... OR com.android.ddmlib.SyncException: Too many open files

Solution Switch DEBUG USB off and on again. It works for me. It seems to be some sort of problem with USB sync when debuggin in my device. When you install and test your application many times on a phone, you may get this error message.Unplug the phone from the USB cable and then plug it in again. I'd go through the previous solutions first. Go through and delete the cached processes you have. Manage Apps > Running > Menu Button > 'Show cached processes'.Then select your app and stop the cached background processes. If any of the above solution could not work, then try to move APK file in different directory and Clean the project Project->Clean.

Android: "Unable to execute dex: Multiple dex files define"

Solution 1)  This is a build path issue. Make sure your bin folder is not included in your build path. Right click on your project, go to properties and then Build Path. Make sure that Honeycomb library is in your libs/ folder and not in your source folder. Include the libraries in libs/ individually in the build path. BTW, you may want to bring in the android-support-v4 library to get Ice Cream Sandwich support instead of the Honeycomb support library. 2)  The reason was that the support library was referenced by two library projects used by my app project but with different versions. In more details: My app depends on 2 library projects FaceBookSDK 3.0 -> which is referencing android-support-v4 ActionBarSherlock -> which is referencing android-support-v4 but with a modified version to support maps. To solve the problem I had to make FaceBookSDK library depend on ABS library instead of the support library directly.  3)  If some of you facing this problem

Android AlarmManager Tutorial

Platform Version : Android API Level 10. IDE: Eclipse Helios Service Release 2 Emulator: Android 4.1 Prerequisite: Preliminary knowledge of Android application framework, and Intent Broadcast receiver. Alarm Manager: AlarmManager has access to the system alarm services. With the help of AlarmManager you can schedule execution of code in future. AlarmManager object can’t instantiate directly however it can be retrieved by calling Context.getSystemService(Context.ALARM_SERVICE) . AlarmManager is always registered with intent. When an alarm goes off, the Intent which has been registered with AlarmManager, is broadcasted by the system automatically. This intent starts the target application if it is not running. It is recommended to use AlarmManager when you want your application code to be run at a specific time, even if your application is not currently running. For other timing operation handler should be used because it is easy to use. Handler is covered in othe

How to solve "com.google.android.gsf.login" has stopped problem ?

Suggestions 1) Remove any  accounts you activated then reconnect them again.. this should fIx and refresh accounts and services. Do factory reset if it does not work. 2) settings>applications>Google Play  and deleted data and cache. Required to log back into Google Play and all worked well from then on. When logged into GP noticed that your download is ready. Interesting thing is that when you started that download previously on your way BUT wifi on and the dwnld was interrupted. I think this may have caused the error. So delete data and cache and restart. 3) You can first try to go into the settings -> accounts and manually remove and reinstall your account to see if that corrects the issue. If it does not, then something got corrupted and you will need to reflash the ROM. All the tools you will need and the ROM is in the development section and ROM sections here 4) Deleting Your accounts in setting (Accounts and sync) then adding them back in. 5) For having