# Unable to Scroll to Element and setText in Mobile App Pop-up screen

**URL:** <https://forum.katalon.com/t/unable-to-scroll-to-element-and-settext-in-mobile-app-pop-up-screen/80927>\
**Category:** Mobile Testing\
**Tags:** mobile-testing\
**Created:** [November 24, 2022, 12:00pm UTC](https://forum.katalon.com/t/unable-to-scroll-to-element-and-settext-in-mobile-app-pop-up-screen/80927 "2022-11-24T12:00:08Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![tdautomation](https://dub1.discourse-cdn.com/katalon/user_avatar/forum.katalon.com/tdautomation/32/20464_2.png) [@tdautomation](https://forum.katalon.com/u/tdautomation)\
**Post date:** [November 24, 2022, 12:00pm UTC](https://forum.katalon.com/t/unable-to-scroll-to-element-and-settext-in-mobile-app-pop-up-screen/80927/1 "2022-11-24T12:00:08Z")

</div>

Mobile Application opens a pop-up screen. I can only tap+scroll to the bottom of the pop-up window and fill the text value. During record I can capture the object which there in the bottom of the pop up screen. I was unable to tap and scroll to that element and setText. I tried with ScrollToText method which is not working.

Do we have any built-in Keyword something like TapAndScrollToElement ?

Could you please someone help me on this?

---

<div class="post-metadata">

**Author:** ![Dave\_Evers](https://dub1.discourse-cdn.com/katalon/user_avatar/forum.katalon.com/dave_evers/32/435_2.png) [@Dave\_Evers](https://forum.katalon.com/u/Dave_Evers)\
**Post date:** [November 25, 2022, 3:15am UTC](https://forum.katalon.com/t/unable-to-scroll-to-element-and-settext-in-mobile-app-pop-up-screen/80927/2 "2022-11-25T03:15:54Z")

</div>

Hi @tdautomation, this might help: [[Mobile] Scroll To Text | Katalon Docs](https://docs.katalon.com/docs/author/keywords/keyword-description-in-katalon-studio/mobile-keywords/mobile-scroll-to-text)

---

<div class="post-metadata">

**Author:** ![tdautomation](https://dub1.discourse-cdn.com/katalon/user_avatar/forum.katalon.com/tdautomation/32/20464_2.png) [@tdautomation](https://forum.katalon.com/u/tdautomation)\
**Post date:** [November 28, 2022, 5:52am UTC](https://forum.katalon.com/t/unable-to-scroll-to-element-and-settext-in-mobile-app-pop-up-screen/80927/3 "2022-11-28T05:52:43Z")

</div>

@Dave_Evers - I already tried with Scroll To Text which is not working.

---

<div class="post-metadata">

**Author:** ![Dave\_Evers](https://dub1.discourse-cdn.com/katalon/user_avatar/forum.katalon.com/dave_evers/32/435_2.png) [@Dave\_Evers](https://forum.katalon.com/u/Dave_Evers)\
**Post date:** [November 28, 2022, 7:25am UTC](https://forum.katalon.com/t/unable-to-scroll-to-element-and-settext-in-mobile-app-pop-up-screen/80927/4 "2022-11-28T07:25:57Z")

</div>

Hi @tdautomation,  
Maybe try this: [Scroll to position/element in KR - #2 by ThanhTo](http://forum.katalon.com/t/scroll-to-position-element-in-kr/57980/2)

Or this:

```auto
int xpos = 10
int ypos = 100
WebUI.scrollToPosition(xpos, ypos)
WebUI.delay(1)

```

---

<div class="post-metadata">

**Author:** ![kreno](https://dub1.discourse-cdn.com/katalon/user_avatar/forum.katalon.com/kreno/32/24257_2.png) [@kreno](https://forum.katalon.com/u/kreno)\
**Post date:** [November 28, 2022, 3:55pm UTC](https://forum.katalon.com/t/unable-to-scroll-to-element-and-settext-in-mobile-app-pop-up-screen/80927/5 "2022-11-28T15:55:28Z")

</div>

Hi @tdautomation. I think that what you are saying is that you are trying to scroll a pop-up screen that covers only a section of the mobile screen. I have not seen a built-in keyword for this but have achieved scrolling a portion of the mobile screen by finding the position of the object that can scroll then finding the height and width of that object and manually scrolling using swipe. Here is an example where only the bottom half of the screen can scroll and I am scrolling down a list for a number of scrolls that we set. Hopefully I understood you correctly and this helps.

```auto
int left = Mobile.getElementLeftPosition(<object in scroll view>)
int width = Mobile.getElementWidth(<object in scroll view>)
int x = (left + width)/2 // x position is in the middle of scroll object
int top = Mobile.getElementTopPosition(<object in scroll view>)
int height = Mobile.getElementHeight(<object in scroll view>)
int y = (top + (top+height))/2 // y position is middle of scroll view
int endScroll = y - (<amount we want to scroll down>)    

int count = 0

while (	Mobile.waitForElementPresent(<object we are looking for>) && count < (maximum number of scrolls) ) {
    Mobile.swipe(x, y, x, endScroll)
    count ++ 
}

```
