Scrolling webpage dynamically?
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
12-06-18 07:28 PM
I have a web application which contains number of rows. I need to process all the rows in the webpage. I am using dynamic attribute feature (incrementing counter) to process each claim. To be specific, the HTML attribute for first element is
/HTML/BODY(1)/IFRAME(2)/HTML/BODY(1)/FORM(1)/DIV(2)/TABLE(1)/TBODY(1)/TR(1)/TD(1)/DIV(2)/DIV(2)/DIV(2)/TABLE(1)/TBODY(1)/TR(1)/TD(1)/DIV(1)/DIV(1)/SPAN(1)
and for second element, it is
/HTML/BODY(1)/IFRAME(2)/HTML/BODY(1)/FORM(1)/DIV(2)/TABLE(1)/TBODY(1)/TR(1)/TD(1)/DIV(2)/DIV(2)/DIV(2)/TABLE(1)/TBODY(1)/TR(2)/TD(1)/DIV(1)/DIV(1)/SPAN(1)
I am using a counter to increment the value in TR() and passing this path to business object access the rows in the table. Lets say there are 30 rows in total in the table and first 10 rows are visible on the page. In this scenario, I am able to access these first 10 rows by passing the path dynamically. When I tried to access the 11th element, I got an error message saying "No elements match the supplied query terms". When I manually scrolled few rows so that they are visible on the screen (let say rows 5-15 are now visible on the screen), then I am able to access the 11th row.
My question is - do I need to scroll to make next items visible on the screen, even though I know the HTML path for that row? Is there any other way than scrolling, where I can access the rows using the HTML path (like blue prism automatically reading the row though it is not visible on the screen)?
6 REPLIES 6
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
12-06-18 07:45 PM
If the HTML is dynamically created as you scroll, then that could be why the element can't be found at first. Or, perhaps one of the attributes in App Modeller specifies that the element must be visible?
Also, with an element spied in AA mode you can use the Focus action to bring it into view.
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
13-06-18 01:01 PM
Thank you for the reply. The HTML is not created on the go. The data is available already and scrolling just makes it visible. Also, in my modeler, I have only the ""Path"" attribute selected and that is also dynamic.
With AA mode, I cannot send the path dynamically as it is not identifying the rows using HTML tags.
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
13-06-18 03:37 PM
OK then probably your remaining options are keystrokes or mouse clicks to scroll down, or (and this is a long shot) injecting some JavaScript to do the scrolling. If you select the Insert JavaScript option in a navigate stage and press the blue i button, you'll see an example.
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
18-06-18 11:45 PM
Hi,
The solution which I think is feasible is to uncheck the Screen visible and visible attributes in the application modeler. Also, instead of scroll down, please try using Global Send Keys as ""{PGDN}"" which works as scroll down. Please let know if this helps.
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
19-06-18 01:25 PM
@John__Carter - thank you for the reply. I will explore more on the JavaScript option.
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
19-06-18 01:28 PM
@sanjana - I do not have any attributes selected other than the HTML path of the element. Rest of all the elements are unchecked. Regarding the {PGDN} option, unfortunately, the webpage is not accepting the page down option. So I need to scroll - either through mouse scroll or using JavaScript code (which I need to explore more on).
