Hi friends,
I have a column A and B in Sheet2 in which it is labeled as Pay period from and Pay period to, respectively.
What I'd like to happen is that when the user chooses every 16th-30th of the month or 16th - 31st of the month, let's say column M in Sheet1 which is labeled as Allowance will go to the column N labeled as Allowance as well in Sheet2. However if the user chooses every 1st-15th of the month, the allowance will not reflect in Sheet2 in column Allowance.
For example:
Sheet1
Column M
Allowance: 1,000
Sheet2
1st scenario
Column APay Period From:Column BNovember 1,2015Pay Period To:>>1,000 in Column M in Sheet1 will not be seen in Column N of Sheet2 as the user chose November 1, 2015 - November 15, 2015.November 15,2015
2nd scenario
Column APay Period From:Column BDecember 1, 2015Pay Period To:>>1,000 in Column M in Sheet1 will not be seen in Column N of Sheet2 as the user chose December 1, 2015 - December 15, 2015.December 15, 2015
However, if the user chooses:
Sheet2
1st scenario
Column APay Period From:Column BNovember 16, 2015Pay Period To:>>1,000 in Column M in Sheet1 will appear in Column N of Sheet2 as the user chose November 16, 2015 - November 30, 2015.November 30, 2015
2nd scenario
Column APay Period From:Column BDecember 16, 2015Pay Period To:>>1,000 in Column M in Sheet1 will not be seen in Column N of Sheet2 as the user chose December 16, 2015 - December 31, 2015.December 31, 2015
I'd like to code this in VBA.
Thank you so much for your help!
Bookmarks