Hi Jay ,
I have not gone into the details , but at first glance Scenario 1 and Scenario 2 should not pose any problem.
Scenario 3 is going to be tough , since on Jan 3 there are 3 time slots. The code is written so that finding the date is done by indexing , and as long as there are only 2 time slots for every date , everything is fine. If there were 3 slots for every date , that could also be coded.
Can I suggest a workaround , which may not be too much trouble ?
For Jan 3 , let us have 4 slots , with the date repeated for the 3rd and 4th time slots i.e. for the 1st and 2nd time slots , the date cell above the time cells will be merged to have Jan 3 in the merged cell ; for the 3rd and 4th time slots , let us have another 2 cells above the time cells merged together , and let this merged cell have Jan 3. For the time slots , let the 3rd time slot have 20:30 ( or 8:30 PM ) in it , and let the next time slot have any time whatsoever. Only all the values in this time slot should be 0 , so that this time slot is there only for symmetry , and in reality it will neither contribute anything nor take away anything. With this symmetry , the code will not have to be changed.
Comments ?
Narayan