Macro

rachel lee

New Member
Joined
Nov 22, 2019
Messages
2
Hi, everyone

I have a spreadsheet that contains data that spans not only across months but also years and I would like to set up a macro that allows me to eliminate data from all the other dates except for that particular month that I'm looking at. Is it possible to set up two macro such that one of it updates the month and another to eliminate all other data to left only the present month?
 

Excel Facts

How to create a cell-sized chart?
Tiny charts, called Sparklines, were added to Excel 2010. Look for Sparklines on the Insert tab.
Hi,

When using a macro ... you can indeed delete data ...

But based on the way you are describing your objective ... you could simply filter your data ...
 
Upvote 0
Hi,

When using a macro ... you can indeed delete data ...

But based on the way you are describing your objective ... you could simply filter your data ...
Yes, I agree and majority of the people that I have consulted recommended using a pivot table instead. However as an intern, when my manager specified that she wants to built in a macro such that when we update a new working file in we can just rely on the macro to sort the data out in a faster way, I kind of have to follow through with what she wants. So do you have any idea how to do so?
 
Upvote 0
Hi again,

As an initial step ... turn on your macro recorder ... and go through your process once ...

You will get a "VBA translation" of all your actions ... and then you will be in a position to improve your code

Hope this will help
 
Upvote 0

Forum statistics

Threads
1,214,523
Messages
6,120,034
Members
448,940
Latest member
mdusw

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