How to search a specific (variable) string from html table and then copy text from the next cell on the same row?

Hello,

I have one little problem. I want to search a specific (variable) string from html table and then copy text from the next cell on the same row. The string to search may not appear in the same row so that’s why I need some help.

How can I do that?

-Jesse

1 Like

Hi @Jesse,

You could search the string and use Get Attribute Activity to know the tableRow index, etc…:

Regards,
Susana

Hi @Susana

Thank you for your advice. Now I can copy text from the next cell on the same row but I don’t understand how I choose by user input variable the right row on Get Attribute?

Here is example where I need to copy information by specific string. The user input variable what automation gonna find from html table. I want to find example Company form (column 1) and then copy “Public limited company” (column 2).

https://tietopalvelu.ytj.fi/yritystiedot.aspx?yavain=20939&tarkiste=FD3B80E3D3656AD15912547886CEFA0227C1A07F

-Jesse

Hello @Jesse,

Hope this could help you :slight_smile:

FindText.xaml (9.6 KB)

You should inform textSearch variable with the string " Company form" and the textResult variable will take “Public limited company” value.

variables

Regards,
Susana

Hi @Susana

Thank you, I will greatly appreciate. This will help me a lot! Unfortunately I don’t have chrome and I don’t have a permission to download it but that’s not gonna be a problem because I can change chrome to IE in Open Browser.
Can you still upload entire folder where is screenshots too. I like to build from beginning and understand how you solve my problem.

-Jesse

Hello @Jesse,

There it goes! :slight_smile:

.screenshots.zip (5.7 KB)

Regards,
Susana

hi @Jesse,

I have a quite similar problem with you :slightly_smiling_face:

best regards,
Hoang Anh.

Hi @Susana

Thanks :slight_smile:
okey, there is still a problem when I changed from chrome to IE. I changed BrowserType to IE in Open Browser. Then I did again indicate to screen in Find Element text and Get text column and wrote String.Format… to selectors etc. Should be the same as yours code so it should be working.

I received this error message. Is this common error message in IE or can be it repaired somehow? I read that error message is due to the UiPath Version. I should have been the latest version of Uipath (2016.2.6379).

Can you check my code if there is some issues what causes this error (see the attachment)? Do you have any solutions how this can be done with IE?

Picture

I attached my code:
Find text test.zip (15.2 KB)

Sorry if I do any extra effort for you :neutral_face:

Best regards Jesse

Hi @Jesse,

There it goes a new version Find text test_v2.zip (18.2 KB)
. There was a problem with the selector and the language selected.

Have you been through the RPA Academy? It’s free to join.

Regards,
Susana

1 Like

Hi @Susana

Its working! Thank you so much. :slight_smile:
I must be considered to join RPA Academy.

Best Regards, Jesse

1 Like