VBA code that finds a value in a col. then returns entire row

Fudging

New Member
Joined
Aug 26, 2022
Messages
16
Office Version
  1. 365
Platform
  1. Windows
Hello,

My task is to filter a somewhat large dataset by project codes and by employee names. This is a really easy task to do in Power Query but I need to develop a tool in VBA that can automate it for people who don't know how to use excel much.
The goal is to give a keyword to look for in a col. (not formatted as a table, so just rows of data) and to create a new mini dataset (in a new tab for now) that has been filtered with that keyword.

The end goal is to do the following: filter and create a new dataset (task mentioned above), convert it to a Pivot table and Pivot Pie Chart, create a new Excel file and paste what was created in that new file. Is it possible to automate all that in VBA? Nonetheless, for now, I need to focus on filtering the data, so please help me out, thanks :)
 

Excel Facts

Excel Can Read to You
Customize Quick Access Toolbar. From All Commands, add Speak Cells or Speak Cells on Enter to QAT. Select cells. Press Speak Cells.
Hello,

My task is to filter a somewhat large dataset by project codes and by employee names. This is a really easy task to do in Power Query but I need to develop a tool in VBA that can automate it for people who don't know how to use excel much.
The goal is to give a keyword to look for in a col. (not formatted as a table, so just rows of data) and to create a new mini dataset (in a new tab for now) that has been filtered with that keyword.

The end goal is to do the following: filter and create a new dataset (task mentioned above), convert it to a Pivot table and Pivot Pie Chart, create a new Excel file and paste what was created in that new file. Is it possible to automate all that in VBA? Nonetheless, for now, I need to focus on filtering the data, so please help me out, thanks :)
What is the name of the sheet containing the data to be filtered?

What is the name of the sheet where the filtered data is to be placed?

What column contains the keyword?

Can you post some data using XL2BB?
 
Upvote 0
Maybe it is possible to define a template based on PQ, and just automate the query update via VBA. Much cleaner, faster and easier.
 
Upvote 0
What is the name of the sheet containing the data to be filtered?

What is the name of the sheet where the filtered data is to be placed?

What column contains the keyword?

Can you post some data using XL2BB?
Hey, thanks for your quick reply!

Found some VBA code that was a little similar to what I needed and got Chat gpt to tweak it a little.

Thanks anyway :)
 
Upvote 0

Forum statistics

Threads
1,224,811
Messages
6,181,081
Members
453,021
Latest member
Justyna P

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top