The .scrollleft() method is used to get the horizontal position of the scrollbar in an element. The below example explains how to find out the position of the scroll bar.
Example Code
Result:
The longest word in the english dictionary is: pneumonoultramicroscopicsilicovolcanoconiosis.
Move the scrollbar to the right and click the button again.