If multiple criteria are met in sheet 1 then paste in Sheet 2 if the dates coincide

Alex92

New Member
Joined
Mar 17, 2018
Messages
1
Hello everyone,

I have started playing around with calendars in excel and i've ran into a wall.
Basically i have created a generic shift pattern spanning for 1 year in Sheet 1, and in Sheet 2 I am trying to create an interactive Attendance calendar. I was able to create a working 30-31 days calendar that can be scrolled through the years and the months. I Was also able to get the code to show me any change (Lieu days) that occurs in the month of march in regards to one of the employees, however this stops working if i change to the next month.

Is it possible to add a formula where it scans the complete year in Sheet 1(Row 6) then if it matches the 30-31 days calendar pattern in Sheet 2(row 9) then it will return a copy of whatever is written in Sheet 1(Row B7....B18 ,coinciding to the specific date) in Sheet 2 Cell G11:AK11 ; G12:AK12 ETC.
The formula so far:

=IF(AND(Shift!$B$7:$B$7="Jerome",Shift!C6=Attendance!K9,Shift!C7="Lieu"),"Lieu","p")

I have tried to also add vlookup and INDEX, however it doesn't seem to properly work.

I have uploaded an example in the following link.
http://www.filedropper.com/holidaycalendar


Any insight will be greatly appreciated.

Thank you!
 

Excel Facts

How can you automate Excel?
Press Alt+F11 from Windows Excel to open the Visual Basic for Applications (VBA) editor.

Forum statistics

Threads
1,223,896
Messages
6,175,259
Members
452,626
Latest member
huntinghunter

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