In this encryption, we are going to use a secret key for encrypting the string. The algorithm used will be AES with CBC (Cipher Block Chaining) mode. The C# code will use PKCS7 padding, as PKCS5 is not available there. In Android, it uses PKCS5 padding internally, even if we specify PKCS7 padding in the […]
Author: Ajay Taneja
How to save data to Firebase in Android?
Objectives: The purpose of this blog is to inform readers on how to save data in Android’s Firebase Realtime database. Simple data kinds, such as strings, can be written to this database, as well as more complicated data types, like Java objects. Pre-Requisites: To use the Firebase Realtime Database in Android, we need to have […]
How to fetch data from Firebase in Android?
Objectives of the blog After reading this blog we will be able to fetch data from Firebase Realtime Database. This data may include simple data types, such as Strings, or complex data types such as Java objects. Pre-requisites We need to have a Android Studio project and Firebase project ready in order to use the […]
How is Session Management done in Android?
In Android, the session management is done using some data storage techniques. This data can be stored in some global variables, database or application’s preferences. But there is an issue with the global variables. The global variables can only retain the data until the application is opened. Once the application gets closed, the global variables […]
Put Elements in Linear Fashion and at the Bottom of the Screen in Android
The best way to put any elements in a linear fashion in Android is to use LinearLayout. Specify the attribute ‘orientation‘ of the LinearLayout to ‘vertical‘. Now any number of elements put inside the LinearLayout will be in vertical order. To align the elements at the bottom of the screen, use ConstraintLayout and add constraints […]
How to Create Alert Dialog box in Android?
The alert dialog box can be used to display a message in a popup dialog box or display a text field for user input or show any custom view in the dialog box. For the view to be displayed in the popup dialog, the view has to be created programmatically or via XML. Then the […]