Type into for each row in datatable application

Hi everyone. I’m newbie learn uipath.
I’m using type into from excel to table of application, but i don’t know how to dynamic type into. It just type in first row :<
Table of application similar table create variables of uipath.
I want each row of excel will correspond to row in table of application.
Please help me. Thanks
image

Hey @Hi_p_H_a_Hoang

Your type into selector should contain two attributes one for table row and the other for table column or field name.

You should be generating the above attributes dynamically from a variable and pass to it.

Hope this helps.

Thanks
#nK

my fuzzy selector not have 2 attribute that. i dont know how to dynamic with this script

<ctrl automationid='tiHT' />
<ctrl name='Records' role='list' />
<ctrl name='Table1' role='list' />
<ctrl name='System.Data.DataRowView' role='list item' />
<ctrl automationid='' role='editable text' />

Hello @Hi_p_H_a_Hoang

You can open the the ui explorer and inspect on a cell, just try to identify the attribute which is determining the cell position, maybe rowNum=1 & colNum=2 like this. If you can identify that then, pass the value to these attributes dynmaicllay to loop through each cell and type the required data.

i has tried. no have 2 attribute like you say but have attribute name idx='number’
i think it could be set dynamic variable. i create a gobal variable at sequence but i cant use in selector. it require create new variable in selector

<ctrl automationid='tiHT' />
<ctrl name='Records' role='list' />
<ctrl name='Table1' role='list' />
<ctrl idx='3' name='System.Data.DataRowView' role='list item' />
<ctrl automationid='TextBlock' idx='2' role='text' />

does idx=‘3’ mean 3rd row?

if so, you can create integer variable e.g. rowNumber

in selector you can use rowNumber variable like this @Hi_p_H_a_Hoang

<ctrl automationid='tiHT' />
<ctrl name='Records' role='list' />
<ctrl name='Table1' role='list' />
<ctrl idx='{{rowNumber}}' name='System.Data.DataRowView' role='list item' />
<ctrl automationid='TextBlock' idx='2' role='text' />

yea, that is row number

then can you try this?

1.create integer variable e.g. rowNumber
2. set rowNumber = index of foreach row activity

2.in selector you can use rowNumber variable

<ctrl automationid='tiHT' />
<ctrl name='Records' role='list' />
<ctrl name='Table1' role='list' />
<ctrl idx='{{rowNumber}}' name='System.Data.DataRowView' role='list item' />
<ctrl automationid='TextBlock' idx='2' role='text' />

Is there any specific reason to use Fuzzy selector

i had declare variable but it still error. Did you have solution for this case ?

No, i think uipath auto choose strict or fuzzy selector to implement

1 Like

Hey @Hi_p_H_a_Hoang

You can go for strict please, because the fuzzy behaves a bit different and it can be used if there is an appropriate scenario.

Thanks
#nK

for testing, just set default value for rowNumber e.g. 3

and see if it can validate

this is strict selector , but when i create dynamic variable it can’t validate, error " this variable not declare in this scope". i had check very but still not work

i had try with default value but it still not work

Hi @Hi_p_H_a_Hoang ,

Change the scope of the rowNumber variable to the outermost Scope and check.
image