Incrimentar range Excel

Hello everyone, I need to increase an Excel range of 20 letters per Excel. example: AB should become AV and so on. Any possible solution?

Hi @Victor_Hugo_Correa

Welcome to Community!!

Could you be more specific and please share input and expected output.

Regards,

Thanks @lrtetala

In this case I have this range "W5;W8:W17;W20:W23;W25:W28;W33:W40;W43:W47;W49:W52;Y5;Y8:Y17;Y20:Y23;Y25:Y28;Y33:Y40 ;Y43:Y47;Y49:Y52;AB5;AB8:AB17;AB20:AB23;AB25:AB28;AB33:AB40;AB43:AB47;AB49:AB52;AG5;AG7:AG8;AG10:AG11;AG13;AG15:AG17 ;AG19;AG23;AG38;AI5;AI7:AI8;AI10:AI11;AI13;AI15:AI17;AI19;AI23;AI38;AL5;AL7:AL8;AL10:AL11;AL13;AL15:AL17;AL19;AL23;AL38 "

I do a split

image

and when I go through the entire range I need to go 20 columns forward for each letter in this case W would be AQ and it would continue like this until I needed it

@Victor_Hugo_Correa

Welcome to the community

You can use excel helper classes which will help you increment

UiPath.Excel.Helpers.ExcelUtilities.ConvertColumnIndexToColumnLetter(UiPath.Excel.Helpers.ExcelUtilities.ConvertColumnLetterToColumnIndex(AB)+20)

this will give AV as result…similarly if you need to incrmeent continuously use this in loop

cheers

@Anil_G Thanks for the solution, it worked correctly

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.