I'm going to show you how to install the date picker on your worksheet I recently
did a video where I showed you how to do this but I didn't put any code in the
background and when I when I saved and open the sheet I found that the the date
that you had placed without the code floats around your page so that it it
doesn't work out very well if you've designed it for a form so what I'm
going to do is I'm going to go through the same initial steps and then I've
added a few steps on so that your date stays in the same place so what we're
doing to do is we're going to the Developer tab and we are going to go to
the insert tool box here we're going to go to the bottom right hand corner with
the screwdriver and the wrench here and we're going to click on this and we are
going to select date and time picker Microsoft date and time picker so if you
scroll down there we go right there you say okay okay so I'm gonna eventually
have it on d3 so I'm just going to click there it's not that it's going to make
that much difference things to notice is the name box shows date picker 1 so
that's let's copy that and now we're going to right click on this on this
calendar and we're gonna go date picker objects and you're gonna go to
properties and you're going to click the check box to make to activate it and
then you're going to apply and then we're going to say ok so now what you're
going to do is you are going to right click again on your on your calendar
there and you're going to go to view code now let's change a few things here
let's change this to worksheet now what you're gonna do is you're gonna type in
with with sheet date picker one and Det date picker one is what we copy from
from the name box okay then what you're gonna do is you're gonna say a height
and a width and I'd like the height to be to be 20 in the width to be 20 just
so we have a little box okay and now we're gonna do an if statement if we're
not clicking on d3 it shouldn't be visible so it says if it
the target is d3 because that's where I want to put it is not if it's not there
it's not yet so when you click on it it's visibles true and then the tops the
bottom and it's offset and it puts a dig in a little bit
link cell target address okay and then we're gonna do an else to our if and
then we're gonna go visible equals false
and then we're gonna go add end with and an end with
now we can compile this because I don't type
particularly well all right so now when we go back to here we click on first of
all we take off the design mode so what I've done is I have saved this this file
I've saved it as date picker too and either the extension Xlsm so
it's a macro so now I'm going to go and I'm going to open it up again and I'm
going to go open and it says datepicker2 here and it will click away
and we'll go to remember we put it in d3 so let's click in d3 and there you have
your drop down for your date picker so let's choose the 25th so that's how you
install your date picker on your worksheet so that it doesn't float
around when you close it please subscribe