Macro to fill in my caledar sheet with my dates adding extra rows when we get duplicates apointments

tonywatsonhelp

Well-known Member
Joined
Feb 24, 2014
Messages
3,194
Office Version
  1. 365
  2. 2019
  3. 2016
Platform
  1. Windows
Hi Everyone,
I have 2 sheets
1 is "Data"
2 is "Cale"

Data has a list of my appointments with my cliennts and their departments
Cale is a calendar Showing dates in row10 one day at a time
Starting 01/03/2019 in column S10
Column D holds the client names


In "Data" I have
A Client Name
B Apointment
C Date
D Code

I want to fill my calendar with my apointments but quite often I have more than one on a day for the same client
so I need it to do this.

go down The list of client names in sheet "Cale" and for each name fill in the dates with the Code in column D,
however if that cell is already filled up, add a row and place it below, but if you have already added a row usit if its not already full.

i'll do an example in a smaller version below

Sheet "Data"Sheet "Cale"
ABCDRSTUVWXYZAAABACADAEAFAGAHAI
10Client Ap.DateCodeClient01/03/1902/03/1903/03/1904/03/1905/03/1906/03/1907/03/1908/03/1909/03/1910/03/19
11BOB07/03/19AWBOBWWYTAWRE
12BOB10/03/19RE
BOBTHIS ROW IS ADDED AS BOB ALREADY HAD A DATE IN 07/03/19
THE 06/03 ALREADY HAS A DATE BUT NOW BOB HAS 2 ROWS SO WE CAN ADD IT HERE!TRTW
13SUE07/03/19JJSUEHYJJ
14BOB07/03/19TW
15SUE01/03/19HY
16BOB03/03/19WW
17BOB06/03/19YT
18BOB06/03/19TR
19
20

<tbody>
</tbody>


Hope that's clear, please help if you can thanks Tony
 

Excel Facts

Enter current date or time
Ctrl+: enters current time. Ctrl+; enters current date. Use Ctrl+: Ctrl+; Enter for current date & time.

Forum statistics

Threads
1,214,543
Messages
6,120,123
Members
448,947
Latest member
test111

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