Uipath Excel Sort and move

Hey Guys, I am new to RPA. I am trying to solve an issue. I have an excel file, i have to sort the file based on the column value and move/copy the related values in the rows to separate sheets, based on the groups. I need seperate this into two sheets. based on profession.
eg: Name Phone age Profession.

   david      789741               25       Developer
   Sam        4561154585       41      Engineer
   Patel       3574120411       33       Engineer
   Mettu      8912456720       35       Developer
   Mumta    8945782301       29       Developer

Can someone help,me?
Thanks

  1. Read the file using excel application scope and read range. Store in a data table
  2. Use sort data table and sort the data table as required
  3. Or, simply you can use these statements to to separate the data tables of required types and then use those to write the data tables to the required sheets

NewDataTable = MainDataTable.Select("[Column Name] = 'Deveoper’ ").CopyToDataTable

Pleas find the attached Zip file of which i created based on your requirement.

CurrenctFileName.zip (20.5 KB)

Thank you so much Mohan, for your quick response. See the attached file of output i got. I would like have the data group to be copied to 2 different sheets. One for ‘Developer’ and one for ‘Tester’, without deleting any info. Thank you again for helping.

xlsx%20-%20Excel

Thank you so much Hareesh,
I would like have the sorted data groups to be copied into 2 different sheets. And I don’t where to use ’ NewDataTable = MainDataTable.Select("[Column Name] = 'Deveoper’ ").CopyToDataTable’ this code.
Sorry, i am newbieto this :smile:. Trying to learn it

Help needed please , not fixed yet2019-09%20-%20Excel

@Hary
Follow these steps:

  1. Add Flowchart/Sequence
  2. Add Read Range, fill in the requirements, pass it to MainDataTable
  3. Add Excel Application Scope, name the new path.
  4. Under “Do” section, add Build Data Table, build the datatable, pass it to NewDataTable
  5. Add For Each Row, for each row in MainDataTable, Assign 4 new variables to the 4 columns using 4 Assign activities
  6. use an If activity, where condition is (Profession Column variable)= (desired profession).
  7. under then section, use Add Data Row, under properties of Add Data Row arrayRow, include the 4 variables u created earlier in this format {variable1, variable2, variable3, variable4}, set the data table to NewDataTable.
  8. use a Write Range, fill in the requirements. check “AddHeaders”.
  9. repeat step 4 to 8 with a new datatable variable for the other profession.

Please complete Level 1 foundation training in academy.uipath.com before you attempt anything further if you have not, if you have, kindly refer back to lesson 9 and lesson 2 as your problem is essentially just application of what you should have learnt in those 2 lessons.

Thank you so much for steps explained and recommendations. I’m so happy to see that this forum is a great help if needed. Thank you again

1 Like

@MythicGold would you be able to create a sample work flow