Questions tagged [android]

Android serves as Google's cutting-edge mobile operating system, empowering developers to create innovative digital devices like Smartphones, Tablets, Automobiles, TVs, Wearables, Glass, and IoT gadgets. To explore Android-related subjects, utilize Android-specific tags such as android-intent, android-activity, android-adapter, etc. Should you have any inquiries regarding the broader Android framework that aren't specifically about programming or development, this link will be your go-to resource: android.

Is there a way to smoothly transition to the starting index of a LazyColumn when utilizing SnapFlingBehavior in Jetpack Compose?

Hey there, I've got a fascinating question to discuss about snapping in Compose development. With the introduction of snapping as a 1st class API for LazyColumn, replacing the Snapper library, a new query has emerged. How can one initialize the LazyCo ...

NativeScript does not acknowledge the permission "android.Manifest.permission.READ_CONTACTS"

Hi there! I am a beginner in mobile development and currently learning Angular 2. I am facing an issue with requesting permission for reading contacts in NativeScript. It seems that "android" is not being recognized. For instance, when trying to execute t ...

Only a blank white display on Android using Cordova

https://i.stack.imgur.com/ekNRF.png Only seeing a blank white screen Checked console in chrome https://i.stack.imgur.com/ttGcD.png Looking for a solution to this issue, I've already tried reinstalling cordova, node, and npm but it's still not working ...

What is the process for packaging a Python kiwi project into an .apk file?

I've been attempting to retrieve the .apk export from my Python Kiwi Project with no luck so far. Even though I diligently followed all the instructions provided in the official repository here, I am still unable to make it work. Can anyone suggest a ...

transmitting data in JSON format through an HTTP URL

I have successfully implemented data transmission from my Android app to a REST Service using asp.net web api. The URLs I am sending, such as , are being processed in the web.api. Now, in the Android client, I am using GSON to convert a complex object in ...

Is there a way to toast the values of an array retrieved from a getter within my object?

My data in the format of a JSON Array looks like this and I am attempting to display the user_review_ids values - 63,59,62 using a toast message. However, instead of getting the actual values, I keep receiving what seems to be a reference to them, such as ...

Cordova is having trouble locating the JAVA_HOME directory

Despite numerous attempts, I have yet to find a solution to my issue. I am in the process of developing a Cordova Android app, but consistently encounter failures with cordova requirements due to an inability to locate JAVA_HOME. The error message I receiv ...

What was the reason behind resolving the 0 height body problem by adjusting the WebView Layout Parameter?

My Xamarin WebView was not displaying my HTML correctly. Even though it was set to fill the whole screen, the body height in the HTML remained at 0px. In addition, I had a div in the HTML with the following style: position:absolute; top:0px; bottom:0px; ...

Deconstructing a JSON Structure

I'm currently developing a D3 damage per second (DPS) calculator and encountering an issue with a JSON object. The JSON object I receive looks like this: {"Sockets":{"min":1,"max":1}, "Dexterity_Item":{"min":165,"max":165}, "Durability_Cur":{"min":581,"ma ...

What steps are involved in setting up a RESTful service for a web application?

After extensive searching, I'm still unclear on how to approach the question posed in the title. The concept of RESTful was introduced to me just this morning, and the more I delve into it, the more puzzled I become. A few weeks back, I undertook the ...

Transferring a collection of files in JSON array format

I have a json object that needs to be uploaded, containing nested arrays with files: [{"key":"value","key1":"value1"}, [{"innerkey":"innervalue","filename":"name"},{"innerkey":"innervalue","filename":"name"}]] The two inner keys within the JsonArray repr ...

Error encountered during AJAX POST request: NETWORK_ERR code XMLHttpRequest Exception 101 was raised while using an Android device

Here is the ajax post code that I am using: $.ajax({ type: "POST", url: "http://sampleurl", data: { 'email':$('#email').val(), 'password':$('#password').val(), }, cache: false, async: false, crossDomain: "true", ...

Implementing Android Volley framework

Hey folks, I could really use some assistance! I'm a beginner with Volley and have been tackling login and registration using it. Specifically, I'm struggling with inserting and retrieving data in the database using JSON arrays and objects. Below are my ...

Unexpected obstacles encountered when implementing the jqTouch JavaScript/AJAX combination on Android

In jqtouch, I'm using vanilla ajax calls to load multiple pages: <li class="arrow"><a href="folder/another/somepage.html" >BRAVIA HDTVs</a><small class="counter">2</small></li></li> I want to incorporate a video ...

The Android platform sends data analytics requests to a server for analysis and

What is the most effective method to track app downloads that are integrated with an SDK? The SDK will provide the necessary methods for initiating download requests. The tracking process involves checking if a file exists. If the file does not exist (ind ...

Contemplating the protection of an Android online platform

In the process of developing an Android app to connect to a http server, I have implemented a web service that sends JSON data to a PHP script on the server. This PHP script then accesses the desired database and inserts the JSON objects. However, my focu ...

Update Android: Sending data to server using PUT request

Feeling a bit frustrated here. Encountering an issue with sending all user inputs via a PUT REST request to the server. Here's how the request JSON object appears on the server: { id: "123", text: "My Name is Peter...", age": 15, name: "Pe ...

Populating AutoCompleteTextView Material dropdown list with Firebase selected value

Currently, I am utilizing the AutoCompleteTextView material drop down list feature to input data into my Firebase database. The process is functioning correctly and accurately capturing the information as intended. Now, I aim to provide my users with the ...

Creating a visually appealing layout by dividing HTML content into two columns within a WebView

Utilizing WebView in my application to display html content for reading ebooks presented a challenge during development. After parsing the ebook and converting it into an html string, I load this string into the WebView component. myView.setVerticalScro ...

Where would it be more beneficial to implement a timer: on the server or on mobile

Currently, I am juggling both server-side (beginning) and mobile development. An interesting conundrum has arisen, but due to my limited experience, I am unsure which path to take. Any insights or advice from the community would be greatly appreciated. I ...

Is there a way to calculate the distance in kilometers between two sets of longitude and latitude in an Android application?

Explanation: This question may sound repetitive, but I have encountered some confusion while working on a live application. The JSON data contains longitude and latitude values which I need to compare with the current coordinates. Despite attem ...

Collaborate and apply coding principles across both Android and web platforms

Currently, I am developing a web version for my Android app. Within the app, there are numerous utility files such as a class that formats strings in a specific manner. I am wondering if there is a way to write this functionality once and use it on both ...

I'm attempting to showcase information from my MySQL database in JSON format, but I'm consistently encountering the same error message

java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.myexample/com.example.myexample.MainActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.hashCode()' on a null object refe ...

Failed to save information in JSON format

I'm currently facing an issue with JSON while trying to implement a register and login feature. The data fails to be stored as intended. Here is the JSON response I am receiving in the log: 02-24 08:24:47.878: E/JSON(2017): {"tag":"register","success":0," ...

Explanation on retrieving JSON data from a ListView and passing it to another activity using SQLite in Android Studio

My goal is to navigate from the HOMESCREEN to a new activity, INTERNETSEARCHSCREEN, and then finally to the EDITINGSCREEN. I have successfully displayed JSON data on a listview but now I want to select a movie from the listview and display specific fields ...

The AsyncTask encountered an error while performing the doInBackground() function

Greetings! I am currently utilizing the AsyncTask to fetch data from PHP files. However, upon running the application, I encounter the following error: List<Online_Messages_item> o; public class RequestPostsTask extends AsyncTask<Void, Void, Bool ...

Struggling with parsing JSON data into a TextView resulting in app crashes

After completing the input, the app crashes without executing any further actions. I have modified the code to display only the UPC and Product information instead of the entire section. Any suggestions on how to fix this issue? If there is a similar que ...

The Material Design 3 DialogFragment doesn't have the same styling as Dialogs created with MaterialAlertDialogBuilder

After migrating to Material Design 3, I've observed that DialogFragments do not have the same styling as dialogs created using MaterialAlertDialogBuilder. Is it necessary to add custom styling to DialogFragments? My assumption was that it should work sea ...

Working with JSON Strings using moshi and retrofit2

The API I am currently utilizing responds with a JSON object nested inside a list structure: [ { "name": "Seattle", "lat": 47.6038321, "lon": -122.3300624, "country": &qu ...

Error in JSON parsing: The key 'item' does not have a corresponding value

After making some adjustments to the JSON response, I encountered a new error message W/System.err: org.json.JSONException: No value for retCode. The complete error: 04-03 12:53:26.624 14366-14366/com.allianz.azemployee W/System.err: org.json.JSONExc ...

The cascading effect is visible on an inactive button contained within an interactive card

I've encountered an issue where I've set the button property clickable="false" inside a card that has properties clickable=true and android:foreground="?android:attr/selectableItemBackground". However, when I click on the card, the button also displays a r ...

Unable to upgrade the Expo SDK version is not an option

I've been working on a project with React Native Expo, and I was testing it using Expo Go on my Android phone. However, after updating the mobile app, I encountered an issue when trying to scan the QR code to test the app. It turns out that the Expo S ...

The WebView.HitTestResult method is currently only receiving <img src> elements and not <a href> elements

I am attempting to open a new window in the Android browser using "_blank". I have set up an event listener for this purpose. mWebView.getSettings().setSupportMultipleWindows(true); mWebView.setWebChromeClient(new WebChromeClient() { ...

Discover the Steps to Navigate a Mobile App Installed on Your Phone Directly from Your Browser

Looking for a way to navigate to my React Native apps using two different scenarios. I have developed web apps with ReactJS. If the mobile app is not installed and I enter an URL like "https://mywebpage.com" in the mobile browser, it redirects to the Goo ...

Transfer information to firebase using a Java class and fetch a single attribute in a different activity

Firebase Database LinkI've been encountering an issue while trying to store data in Firebase using a particular code snippet. Previously, I was able to save data by creating new children under users>uid without any problems. However, now that I am att ...

Troubleshooting issue with linking Firestack in React Native

Having some trouble with integrating firestack into my react-native project. I followed these steps: Ran npm install react-native-firestack --save But when I attempted to link it: Ran react-native link react-native-firestack I encountered this erro ...

What is the process of sending JSON parameters in an Android web service request?

Possible Duplicate: How to send a JSON object over Request with Android? Being new to Android development, I encountered an issue when trying to send requests to a web service in JSON format. After researching online, I came across this code snippet f ...

Generating clickable markers that trigger an AlertDialog to appear in real-time

I am currently working on dynamically adding markers to a map, pulling data from JSON. The marker addition process is functioning correctly, as I can successfully add multiple markers in various locations. However, when I click on a marker, I want an alert ...

I am experiencing difficulties with socket.io and my Flutter app is unable to establish a connection with the server or backend component

For the backend of my flutter app, I utilized socket.io and node.js. I created an index.json file and implemented a function on a page to establish a connection between my app and the backend. However, I am facing issues with it not working as expected. Be ...

Move massive data between Android and Node.js

I am currently working on an Android photo-taking app developed in React Native that needs to be paired with a React Electron gallery-type app on the user's computer. There is a requirement for transferring a large number of photos directly to the computer ...

How can I obtain a JSONObject as a response in REST Client?

I am currently following a tutorial at https://github.com/excilys/androidannotations/wiki/Rest%20API and I'm looking to bypass the JSON to POJO conversion process and instead work with pure JSONObject (or gson's JsonObject). What should I include in the se ...

Initial loading issue with HTML5 Canvas in Android WebView

As I work on developing a HTML5 canvas-based game within a WebView of an existing application, I encounter a puzzling issue. Upon the initial run of the game, everything seems to be in order - logs indicate that it's ready and running, yet nothing is ...

Unleashing the Potential: Unraveling the Secrets of Deploying a Raffle Ticket System

I am currently developing an innovative android app that incorporates a thrilling raffling system. To ensure user security and authentication, individuals are required to log in via Google OAUTH. After successfully logging in, users must perform specific a ...

Is it possible to use Selenium for testing mobile web applications?

Seeking guidance on how to conduct automated testing using Selenium or another Ruby-aware tool for Android devices (Android Browser) and iPhone/iPad (Safari for iOS). Any recommendations or strategies would be appreciated. ...

How to use Gson to deserialize JSON in Java

Struggling with deserializing json in java using gson. This is the json I am working with: {"races":[ {"id":1,"mask":1,"side":"alliance","name":"Human"}, {"id":2,"mask":2,"side":"horde","name":"Orc"}, {"id":3,"mask":4,"side":"alliance","name":"Dwarf"}]} ...

The functionality of jQuery touch events on iOS devices is not functioning properly

I'm encountering issues with jQuery touch events on iOS devices. Here is my current script: $(document).ready(function(){ var iX = 0,iY = 0,fX = 0,fY = 0; document.addEventListener('touchstart', function(e) { ...

Using either Google Maps or a customized mapping solution in a React Native application

I am currently developing an application that allows users to input addresses and locate them on a map. I am wondering if implementing AI technology or utilizing specific libraries is necessary in order for this feature to function properly within a reac ...

Decomposing the Retrofit response.body()

I am having difficulties with implementing Retrofit and understanding how to interpret the response body. I believe that there might be an issue with mapping my JSON data to POJO because the output is not what I expected when I print it out in the log. He ...

How to display JSON images in an Android listview

I'm facing difficulty in loading images from a JSON file to the listview on my Android app Although I know that I need to use BitmapFactory.decodeStream, I am unsure about how to proceed with the implementation Below are the details of my adapter an ...

The process of parsing JSON to send a verification code from the server to email is experiencing technical difficulties

Consider the following code snippet : @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.register); emailto= (EditText)findViewById(R.id.editText3 ...

Having issues with an Android app crashing on Android 12+ devices when receiving push notifications in the background. This problem is occurring with an

An error occurred with the Firebase-FCMService while running the app. The specific process and PID are as follows: com.petbacker.android, 4405. This issue is related to an IllegalArgumentException stating that targeting S+ (version 31 and above) requires e ...

Steps to create a full screen notification similar to WhatsApp call on React Native Android platform

Currently, I am working on integrating a notification system that can display full-screen notifications, even on the lock screen similar to a WhatsApp call using React Native for Android and OneSignal. Unfortunately, I have been unable to find a reliable ...

I am having difficulty extracting an image from the JSON data retrieved from the service and displaying it in the recycler view

This is my custom Adapter class where I am facing an issue with parsing images from JSON data retrieved from a service. CustomRecyclerViewAdapter.class public class CustomRecyclerViewAdapter extends RecyclerView.Adapter<CustomRecyclerViewAdapter.ViewH ...

Comparing PhoneGap and React.js to NativeScript for Android hybrid app development

At our organization, we experimented with creating a hybrid app development framework using Cordova/Phonegap as the foundation. Unfortunately, this approach resulted in significant performance issues. As a solution, we turned to react.js to enhance front ...

Apps created with PhoneGap will maintain the original sizing of web pages and not automatically resize for display on Android devices

After successfully porting my web-based tool to Android using PhoneGap from my Github repository, I encountered an issue with the display on Android devices. The app loads up too big for the screen, forcing me to constantly scroll around to see and access ...

verifying for incorrectly formatted object within a JSON list

I'm facing an issue where I need to convert a list of objects into an array. Everything works smoothly when the objects are in good shape, however, it becomes quite challenging to identify which one is malformed when dealing with 4000 records. Is there a w ...

Strip  symbol out of json output

Currently, I am utilizing the Volley Library to parse JSON data. However, when parsing the response, it contains a certain symbol at the beginning: JSON RESPONSE : {"category":{"420":{"key":420,"label":{"420":"Acacia"},"count":"1"},"421":{"key":421 ...

Transferring a JSON array from one activity to another using intents

I had a similar question before, but the solution didn't work for me. So I decided to ask again. My issue is with passing a JSONarray from one activity to another using an intent. In my code, I connect to a MySQL database and retrieve user data whic ...

"Encountering a NullPointerException on Android while trying to parse JSON data fetched from

Encountered an issue while attempting to link phpMyAdmin with MySQL database in Android programming. Here is the segment where I endeavored to receive the output from my php method: public boolean obtainLogin(UserModel userModel) { String username = u ...

Converting an AngularJS web application into an Android mobile application: A step-by

Looking for guidance on converting an AngularJS application into an Android application. Any assistance in creating this transition would be greatly appreciated. I am specifically interested in incorporating angular routing and angular ui-routing. ...

Struggling to retrieve JSON data from a URL and unsure how to manage errors and exceptions

Currently, I am attempting to retrieve JSON data from a specific URL within an Android application. The URL in question solely contains JSON information with no additional content. At this time, my main objective is to fetch the contents of the URL and sto ...

Voice recognition feature in the latest version of Chrome on Android devices

When using a PC with Chrome 25 (non beta), I see a microphone icon that prompts for input when clicked. After speaking, my alert call is successfully executed. However, on a Galaxy Note smartphone with Chrome 25 and an Android 4.04 operating system, the sa ...

Download Android contact information in csv layout

Hello, I am new to Android and interested in learning how to export my contacts into a CSV format. I need to transfer the file to a web server and store it in a centralized database using MySQL. Using vCard is not my preferred method... Alternatively ...

tips on launching a pre-existing react native project

Trying to run a project downloaded from someone else can be quite challenging. I encountered some issues where the project just wouldn't start, and now I'm completely stuck. Can anyone help me out? https://github.com/sunlight3d/react_native_v0.4 ...

Transferring a JSON object from an Android device to a server

I am having some difficulties sending JSON to an HTTP server in the following format: {"deviceID":3852883413434, "depth":2,"location":{"xCord":46.232, "yCord":42.4421},"size":3} Here is the code snippet I have written for Android, but it doesn't see ...

Is there a way to receive notifications on an Android device when the real-time data updates through Firebase Cloud Messaging (FC

I am attempting to implement push notifications in an Android device using Firebase Realtime Database. For example, if an installed app is killed or running in the background, and a user posts a message in a group (resulting in a new child being added in t ...

Ways to resolve the issue of truncated lines while displaying HTML content in WebView on Android devices

When displaying content in a WebView, I am encountering an issue where the top and bottom lines are being cut off. What steps can I take to resolve this problem? My current approach involves using HTML to present data within the WebView. ...

What are the steps to allow access to react-native-camera after initially denying permission?

When you first launch the app and go to the camera, a Permission modal pops up on Android or iOS with the options of allowing or not allowing access. The react-native-camera package is used in this scenario. It includes a property called notAuthorizedView ...

Having trouble with sending images using Node-gcm and Nodejs

My current project involves an Ionic app that communicates effectively with a Node.js server. The app serves as a notification system utilizing node-gcm, but I have encountered an issue - gcm does not support sending images directly due to payload size lim ...

What could be the reason for a missing button in the Bootstrap navbar on smaller devices?

I'm new to Bootstrap and noticed on smaller devices, there is no visible button to tap for displaying the menu items. However, tapping on the upper right-hand side does reveal them. What could I be missing here? index.html <!DOCTYPE html> ...

OutOfMemoryError caused by Bitmap

I'm experiencing an issue with this error. I created a favicon parser from URLs using the following code: public class FavIconParser { public static String extractUrl(String url) { StringBuffer sb = new StringBuffer(); Pattern p = Pattern.compile ...

top-notch cloud option for handling JSON requests

I am currently developing an Android app that needs to access JSON data from three different websites at specific intervals throughout the day. In order to simplify this process, I am seeking a cloud solution that enables me to utilize scripting languages ...

Capturing user input for LazyList in Jetpack Compose to display dynamically

I've hit a snag trying to display User input in my LazyList. The User's input is collected via the ModelBottomSheet, but despite attempting to save it, I can't get it to show up in my LazyList. I suspect there might be an issue with how the ...

Retrieving data from an API on an Android platform

While attempting to retrieve data from an API that requires a key, the output states "app key not found". However, I have successfully tested it using Postman. Below is the code snippet: public class fetchData extends AsyncTask<Void,Void,Void> { ...

"Lost and Found Hub" app integrating ViewPager, Fragment navigation, ListView display, and JSON data storage

I am developing an application for a lost property office. The app is designed with four tabs, and each tab should showcase announcements uploaded by users. When a user clicks on an item, a new activity opens to provide more details (similar to a news feed ...