Add Sequence numbers Based on Dates

arcaidius

New Member
Joined
Dec 4, 2018
Messages
24
I have one excel file where data is entered, and then transferred to another excel file with macros. On the second excel file I would like a macro that inputs a sequential number for each day in column A, and a sequential number for each week (or Month if week isn't possible) in column B. The Date is contained in Column D. A formula does not work because the cells are getting pasted over, so I need this to be a macro to enter the Sequence number after the data is pasted from the first work book. The purpose is count the number of things employees are entering each day, week, etc.

Thank you guys for your hep.


ABCD
# Day# Week Date
<colgroup><col width="68" style="width: 51pt; mso-width-source: userset; mso-width-alt: 2486;"> <col width="64" style="width: 48pt; mso-width-source: userset; mso-width-alt: 2340;"> <col width="39" style="width: 29pt; mso-width-source: userset; mso-width-alt: 1426;"> <col width="86" style="width: 65pt; mso-width-source: userset; mso-width-alt: 3145;"> <tbody> </tbody>
 

Some videos you may like

Excel Facts

Is there a shortcut key for strikethrough?
Ctrl+S is used for Save. Ctrl+5 is used for Strikethrough. Why Ctrl+5? When you use hashmarks to count |||| is 4, strike through to mean 5.

Jeffrey Mahoney

Well-known Member
Joined
May 31, 2015
Messages
1,768
My 2 cents:
If you are adding sequential numbers to a dataset that are allowed to be changed you are asking for trouble. The number of entries for each day could change, therefore, the macro would have to evaluate all the values over and over again. The best thing to do is create a 3rd table to show the count for each date / week / year.

Without a data set and an example macro, I'm not I could do anything.
 

Watch MrExcel Video

Forum statistics

Threads
1,114,469
Messages
5,548,196
Members
410,824
Latest member
Bobmn4
Top