cancel
Showing results for 
Search instead for 
Did you mean: 

Moving the Filtered data to another column

Santos26
Level 3

Hi Team,

I'm facing an issue with filtered data in Excel. What I want to do is move the filtered data to another column. What's the best approach or action for this?



------------------------------
Ace Rigor Santos
------------------------------
4 REPLIES 4

Hi Ace Rigor Santos,


Filtering will reduce the no of rows in excel.
Are you looking to create a new worksheet based on filtering?

I can think  two approaches  but it might be done different ways.
1) Read the data from excel  and get the data as collection and  use filter action in collection manipulation  and write the data back to excel
2) USe filter in excel itself with out saving the changes read the data as collection  from the filtered data  and write back that collection to excel



------------------------------
-----------------------
If I answered your query. Please mark it as the "Best Answer"

Harish Mogulluri
Lead developer
America/New_York TX
------------------------------
-----------------------
If I answered your query. Please mark it as the Best Answer

Harish Mogulluri

Hi Harish,

I've applied the filter. My next step is to move the data from column AE to column AG and replace it with 0. I initially tried using the 'Copy and Paste Worksheet Range' action, but I encountered an error. I then attempted the 'Select, Copy, and Paste' action, but I'm still getting an error

29091.png



------------------------------
Ace Rigor Santos
------------------------------

Hi Ace Rigor Santos,


In general if you use the code stage  to filter the excel it will only give the filtered data but based on the screenshot provided it is giving filter icon at the column name which means it is filtered manually  is that correct? , The same option is not available in code. I have  tried to replicate manual filter vs code in the past having trouble doing that. 

I think the issue you encountered might be due to mismatch between the rows the rows copied and the original rows is different that might cause the issue.if you use the code stage to filter you may not see the error in copy and paste action.

But if you are looking only updating the value based on the column 'AE' I would write formulae instead of trying to copy and paste it.



------------------------------
-----------------------
If I answered your query. Please mark it as the "Best Answer"

Harish Mogulluri
Lead developer
America/New_York TX
------------------------------
-----------------------
If I answered your query. Please mark it as the Best Answer

Harish Mogulluri

Hello,

Another possibility that can be flexible is the use of VBA script to support execution through the code stage, if you can't achieve it through the utility.

Regards,



------------------------------
Leonardo Soares
RPA Developer
------------------------------
Leonardo Soares RPA Developer América/Brazil