Tag Archives: InputStream

Client-Server Programming in Android. Send Message to the Client and Back.

By | May 1, 2017

Hi all, Today I will show you how you can implement Client-Server architecture in an Android environment.   Watch Video Demo   Below is the demo of the app we are going to build.   Watch Video Tutorial   I wil be explaining the code in the below video tutorial. If you have any comments,… Read More »

Downloading Multiple files(Images etc..) in Android Simultaneously/or in Batches in Android using ThreadPoolExecutor.

By | June 10, 2016

CPUs with multiple cores have almost become the standard in Android devices. This means multiple operations doesn’t have to wait to be executed on a single thread. They can rather run on multiple threads in parallel where each threads gets executed on a single processor. For example imagine an operation where multiple images have to… Read More »

Bluetooth Demo in Android – Listing paired Devies, Find other Online BT devices, Connect to a BT Device, Communicate between connected BT Devices ( Chat ).

By | March 10, 2016

In this Demo we will see Check compatibility of the device. Turn On/Off Bluetooth, Making it discoverable List Paired Devies. Check for Online Bluetooth Devices. Connect with a Device. Communicate between Connected Bluetooth Devices. Disconnect from Device. You can download the complete Android Studio Source code at the end of the post. Before We start… Read More »

Uploading Image to Server – Android Eclipse Version.

By | February 18, 2016

Hi all, In today’s tutorial I will show you how to send an image to server using POST method in ANDROID. If you are working in Android studio, then checkout the article here. Uploading an image to server is a basic requirement in many of our application. Sending data to server which is using a… Read More »

How to copy a file to another saved in SDCARD in Android?

By | December 30, 2012

Hello all… This tutorial explains how to copy a file contents to another in Android. The file to copy is saved in SDCARD, however you can change the path to save it in your application sandbox. if you want to save it in your sandbox, change the path to /data/data/your_packagename/your_file.extension Now we will see the… Read More »

How to read and write files to SDCARD and application SandBox in Android – A complete example?

By | September 6, 2012

Here is a complete example of How to read and write files to SDCARD and application SandBox in Android. First create a new project and inside the mainActivity paste this code. Now create another class named MyFile.java and copy this code into it. Now the layout for the xml file. Note you should give this… Read More »

How to load an image from the assets folder in android?

By | August 9, 2012

Here is a simple example showing how to load an image stores in assets folder in android? Done.

How to download a file from a remote site in android? – Another simple example – Method -3

By | May 7, 2012

Hello all ……. I have shown many examples on how to download and upload files in android through this site. These are other methods for downloadign a file in android. 1. How to Download an image in ANDROID programatically? 2. How to download a file to your android device from a remote server with a… Read More »

How to download a file to your android device from a remote server with a custom progressbar showing progress?

By | April 29, 2012

Actually this is really simple. I have already posted an example for how to download a file in this post. How to Download an image in ANDROID programatically? This is another one little different with a progressbar included. Previously I have shown three other methods to upload files to a server. Check these posts to… Read More »

How to read and write a text file that is stored in your application sandbox in ANDROID?

By | April 22, 2012

Hi all….. In this post I will show you how to read a text file in ANDOID. Let your file is in the your application sandbox of your ANDOID project, i.e the file’s location is /data/data/your_package_name folder. To view this folder -> open File Explorer and expand each folder. For this example to work first… Read More »

How to Upload Multiple files in one request along with other string parameters in android?

By | August 16, 2011

Hello everyone, I have shown two methods to upload files in android. In today’s tutorial I will show another simple method to upload files. With this method you can upload multiple files in one request + you can send your own string parameters with them. Here is another method on working with uploading of images.… Read More »

How to Download an image in ANDROID programatically?

By | July 7, 2011

Hello everyone.. In one of my tutorials I have shown you how to upload an image in android.. In todays tutorial I will show you how to download an image into your phone programatically. I am just picking up an image url from google to show the download. Previously I have shown three other methods… Read More »

ANDROID – Upload an image to Server in Android Studio

By | April 25, 2011

Hi all, In today’s tutorial I will show you how to send an image to server using POST method in ANDROID. Uploading an image to server is a basic requirement in many of our application. Sending data to server which is using a PHP Script is already explained in this example . Now in this… Read More »

How to read a folder in the assets directory and read files from it in android?

By | March 12, 2011

File reading is important in android. For the put the files in the assets folder. We can able to read foldername filename Contents of the file First we read the name of the folder. “folder_array” contains all the names of the folder Then if the path is set to Then the list of file name… Read More »