I'm trying to create a data collection tool in a research study that will only provide the last 30 calendar days from the date it is opened. I'm using Excel Calendar, and I put the information for the date ranges in two cells on the side of the calendar, where the 30-day period start date is L4 (4,12) and end date is in L3 (3,12). I want to lock and black-out the calendar days that are not within that 30-day range to minimize confusion and error.
I pasted what I wrote into VBA so far. I practiced with 4 consecutive calendar days (all in row 6), where 2 of them should have been blacked out because they were outside of the 30-day range.
(Note: each calendar cell has two blank cells below it for data entry, which is why I want to lock and blackout 3 cells at a time for each calendar day.)
-----------------------------------------------
I also tried this:
------------------------
None of this has worked. I'm not sure if I'm getting the DateValue Function wrong, or if I'm missing something else. I was hoping to eventually use a Loop function once I got this step figured out, but I haven't even gotten the first part down...
Any help would be much appreciated!!!
----------------
EDIT:
This question has been cross-posted at the following URLs:
http://www.mrexcel.com/forum/excel-q...-calendar.html
http://database.ittoolbox.com/groups...lendar-5939485
Initially, I did not understand that cross-posting within a short timespan is not recommended. I'm under a bit of a time crunch and wanted to figure this out as efficiently as possible. Now I understand that sharing the cross-post URLs is part of that process. Thanks!
Bookmarks