Robot breaks "Type Into" action on second row(says invalid in red), but works fine on the first

Hi everyone,

I’m building a robot that inputs data from an Excel file into SharePoint — one row at a time using a For Each Row loop. The first row works perfectly and gets entered into SharePoint as expected.

However, when the robot tries to process the second row, it fails. All the “Type Into” activities suddenly show as “Invalid selector”, even though they worked fine for the first row. I’m not sure what’s causing this issue after the first successful input.

I’ve tried repairing each selector by doing the following:

  • Open the “Type Into” activity
  • Click Edit Selector > Open in UI Explorer
  • Click Repair
  • Select the correct input field in the UI
  • In Selector Editor, I’m using the one starting with <html app=...>
  • In Selected Items, I include all available attributes
  • The Validate button turns green (so everything looks good)

Even after doing this for each input field in the process, the same thing happens: the first row works, then everything fails for the second row and all “Type Into” activities show as invalid (highlighted in red).

I’ve run out of ideas and really need help to solve this. I have a deadline at work this week and need to get this working. Any advice would be deeply appreciated!

Thanks in advance


this is how I tried to repair it but only work for the first row, the second row changes the selector status to “Invalid” in red as you can see in the previous attachments, hence the bot starts to bounce back as all the type into actikns are now all in “invalid status”

Hi @Stephan_Sauter

From the screenshots, looks like, first type into for company is working fine second time too but it’s failing at 2nd type into

Is that right?

Welcome @Stephan_Sauter to the UiPath community!

Can you share a screenshot of the error message so we know what type of exception it is.

Having all attributes for every selector is not necessary. Its important to have a few key attributes selected.

This is just a guess at this point but I would look at any value with a number in it and maybe look at wildcarding them with an asterisk *

Cheers

Steve

System.IO.File.SetCreationTime(filePath, newDate)
System.IO.File.SetLastWriteTime(filePath, newDate)
System.IO.File.SetLastAccessTime(filePath, newDate)

Hey @Stephan_Sauter okay i can see you are using classic activity and first you are open browser then read the file and inside the for each you are using type into.

so first thing you have to change is -
1- use the attach browser activity and inside the for each row activity.and use the anchor base activity


fine tune the selector. enable the wait for read

cheers

Please try to fine tune selector and make it more dynamic.