How to show a progress bar to load a process in each line of the list one at a time?

I want to set a progress bar on each line of the View.A list. A progress bar should start or show progress for downloading files. I want to set this progress bar on every line of the list. And the progress bar will start one after another in each row after one progress has been achieved.

+4
source share
1 answer

First, you want to create a custom ArrayAdapter and add a progress bar to each of the elements by doing this by adding a ProgressBar to the layout you are inflating on. After you want to catch the download listener so that you can listen to the progress and update the progress bar. If you want them to load one at a time, I suggest adding a variable to your object or making an ArrayList<Boolean> to check if the previous elements are loaded.

An example of creating an ArrayAdapter It also shows how to create a layout for the lines that you will be pumping.

0
source

All Articles