How to scroll down in appium

I know when i want to scroll down to specific element in appium use the following driver.ScrollTo(value);
but this value is changed every time and can’t detect it i can not use this value to scroll until find the element, but this element is the last element in my page and number of element in the page is changed between user and another.
So, there is any other way to scroll down till the end of the page ?

Try this way. It used Touch Action class to scroll the page until specific text is found on page

public void scrollTillTextFoundOnPage() throws InterruptedException{

	// Pre Condition for getting scroll area
	System.out.println("Clicking " + _driver.findElement(By.xpath("(//android.widget.TextView)[2]")).getAttribute("name"));
	// Get area for scrolling by getting coordinates using elements displayed on screen
	List <WebElement> elem = _driver.findElements(By.xpath("(//android.widget.TextView)"));
	System.out.println("elem.size()  " + elem.size());
	System.out.println("elem.get(1).getLocation().getX()  " + elem.get(1).getLocation().getX() + 
					   "  elem.get(1).getLocation().getY()  " + elem.get(1).getLocation().getY());	
	System.out.println("elem.get(elem.size()-1).getLocation().getX()  " + elem.get(elem.size()-2).getLocation().getX() +
					   "  elem.get(elem.size()-1).getLocation().getY()  " + elem.get(elem.size()-2).getLocation().getY());
	// Get Scroll coordinates of first element and second last element
	int x1 = elem.get(1).getLocation().getX();
	int y1 = elem.get(1).getLocation().getY();
	int x2 = elem.get(elem.size()-1).getLocation().getX();
	int y2 = elem.get(elem.size()-1).getLocation().getY();
	TouchAction tAction=new TouchAction(_driver);
	// Perform scroll using a terminating condition
	do  {

	if (_driver.findElements("Malta (+356)")).size()>0)
		_driver.findElement("Malta (+356)")).click(); // Once scroll is performed. Do target action
	} while(_driver.findElements("Malta (+356)")).size()==0);