Category "android"

How to run a method every X seconds

I'm developing an Android 2.3.3 application and I need to run a method every X seconds. In iOS, I have NSTimer, but in Android I don't know what to use. Someo

How to create a EditText with the top corner rounded and the bottom rectangle

I have a simple background in my drawable folder, just a border that I use on my EditText : <shape xmlns:android="http://schemas.android.com/apk/res/and

how to draw poly line on google map in android

@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); requestWindowFeature(Window.FEATURE_NO_TITLE); se

Implementing search bar and getting 'java.lang.Object[] java.util.Collection.toArray()' on a null object reference error

I am new to android studio and I have been trying to implement a search bar onto my app and I've come across a building error. It install's fine but when I try

file is encrypted or is not a database: , while compiling: select count(*) from sqlite_master;

I have an app that has been in production for years. It ships with the standard Sqlite DB. The lastest version of the app has SqlCipher 3.5.6 library integrated

Android in-app purchase setup keeps returning - Billing service unavailable on device. (response: 3:Billing Unavailable)

I'm trying to implement In-app billing in an app currently on google play store. I keep getting the same result for any device running the app. (I have read the

Bitmap image to base64 conversion

I am trying to convert a bitcode image to base64 format. I tried to code like public static String encodeToBase64(Bitmap image, Bitmap.CompressFormat compressF

TabLayout gravity center is not working

I have a TabLayout, where I want the tabs to be displayed in the center of the screen. Below is the XML for my TabLayout. <android.support.design.widget.Tab

Location of android SDK has not been setup in preferences

I am getting this error: I have installed ADT and SDK using install new software in Eclipse. I am using Eclipse Java EE IDE for Web Developers. Version: Keple

disable the scroll effect of the action list

I've got a GuidedStepSupportFragment fragment like this. public class SampleStepFragment extends GuidedStepSupportFragment { @NonNull @Override pu

Android "elevation" not showing a shadow

I have a ListView, and with each list item I want it to show a shadow beneath it. I am using Android Lollipop's new elevation feature to set a Z on the View tha

getSupportFragmentManager getFragment without tag or id

I'm developing an Android 3.1 Tablet application. I'm using ViewPager and fragments on one activity. My problem is that I don't know how to set an ID or Tag to

Out of memory error: Java heap memory on Android Studio

How do I fix java.lang.OutOfMemoryError: Java heap space when compiling my Android project? I get this after I upgraded to version 1 of Android Studio. But, I d

Make ImageView fit width of CardView

I have a CardView with rounded corners, I want to have an ImageView at the top like shown in the example taken from the material design guidelines below. <

Android Custom GridLayout with Text+Image

In my application, I am trying to get the details of a set of users from a web-service. Then, I want to display the Image of each user along with their names in

Searchview with endless scrolling in android

My Adapter public class AdapterItem extends RecyclerView.Adapter<RecyclerView.ViewHolder> { private final int VIEW_ITEM = 1; private final int VIEW_PRO

I have an error when compiling android Q kernel

I have this error:CROSS_COMPILE_ARM32 not defined or empty, the compat vDSO will not be built when i trying to compile android kernel. My phone is aarch64, and

How to create two columns with space beetwen in react native - flatList

Hi i'm new in React Native. I am trying to create two columns layout with space beetween using react native component called flatList. Here is my view Code:

Hidden bottom item in LazyColumn - Jetpack Compose

I am trying to create a list of items with a hidden button at the bottom. By default the button is not visible on the screen. If a user scrolls to the bottom of

Android 5.0 IllegalArgumentException: Service Intent must be explicit: on com.google.android.location.internal.GoogleLocationManagerService.START

I'm trying to retrieve the location of the device calling the method connect of the class LocationClient in my activity, however when the call is made the syste