Create Custom Index for Uipath

HI @Md_Hidayat

You can also try with this expression

(From d In Dt_inp.AsEnumerable
Let b=d(0).ToString
Let c=Dt_inp.Rows.IndexOf(d)
Let res=New Object(){b,c.ToString+"a"}
Select Dt_Out.Rows.Add(res)).copytodatatable

Steps like this

  • Read range input file and store in the variable DT_inp or something.
  • Add Data column “Index” to DT_input variable
  • Assign another datatable variable “DT_out” = Dt_Inp
  • Clear Datatable Dt_Out you will get the headers without the data.
  • Assign Dt_input = The linq expression i shared
  • write range Dt_out you will get the output

Hope this helps

Regards
Sudharsan

1 Like