How to type into various UI elements

Hi

Maybe someone can assist? I am trying to build a automation the types in “0” into each of the block highlighted in yellow. The problem is that on each scenario the items listed change meaning that it can have more than two items to type “0” into or it can have only one.

@hwessels

  • Identify Elements:
    • Use UiExplorer to pinpoint the yellow-highlighted blocks dynamically.
  • Build Dynamic Selector:
    • Create a dynamic selector that can locate these blocks reliably.
  • Iterate and Interact:
    • Use a loop (e.g., For Each) to iterate through each identified block.
    • Inside the loop, use a Type Into activity with the dynamic selector to input “0” into each block.
    • Increment the values using index

@hwessels,

Use For Each UI Element activity for this. This will handle dynamic number of fields automatically.

Use it in Use Application/Browser Scope.
image

Thanks,
Ashok :slight_smile:

Hi, Thank you for the feedback, however it does not want to work in use application? Is I select the ui element it does not save it? Any suggestions?

Hi, Thank you. How do I save the identified element? See screen print below, not sure what to include in List of items?

@hwessels,

You are using wrong activity. You should be using For Each UI Element activity. Activities - For Each UI Element

Thanks,
Ashok :slight_smile:

No sure what I am doing wrong but after indicating the element it show that it was not indicated? see below

@hwessels,

Select the Ui Element and click on Confirm

Then click Save & Close.

Thanks,
Ashok :slight_smile:

Thanks, sorted! however I get the following error when running:
For Each UI Element: Error HRESULT E_FAIL has been returned from a call to a COM component.

@hwessels,

This happens mainly when the Ui Element you are trying to iterate are not fully loaded yet.

Solution:

Add Check app state activity before this For Each Ui Element activity to be sure the Ui Elements are available and ready to iterate.

Thanks,
Ashok :slight_smile: