AutoScroll TextView With Spinner

AutoScroll TextView can be added to Spinner, ListView or any other component as required or as needed. This tutorial will allow us to scroll text inside a TextView in a spinner.

Generally, textview will marque the text only when it is focused. By using the below code, the textview will automatically scroll even without focus to textview with using Spinner.

Check out my previous post on AutoScroll Text View here. Follow the steps below to get this working with a spinner:

Step1: Create a new android project in your android IDE.

Step2: Write following code into main layout:



Step3: Create and write following into raw.xml:



Step4: Write following into main activity file:




Step5: Run for the output below:





Checkout my last post published on SlidingPaneLayout Example

Leave a Comment: