Hello friends,
I have a "Data Entry" userform which users use to input ceratin data which are getting captured in a particula sheet in the same workbook.
In the userform, there is a textbox which holds the date ("mm-dd-yyyy" format) as user selects the date from a calender(placed in this "Data Entry" userform).
I want the code to prevent users from entering any data on the form and give a message (and should close the form) if the date(on which they open the form to submit the info) > 23rd of that month.
To be more precise, IF user's input date(in other words, the date when they open the form)>23rd of that month THEN alert message should be popped up and form should be closed ELSE proceed.
[Note:So, date(23rd) should be fixed but "month" and year should change as the time progress....I am not able to make this dynamic]
I tried doing this by using 'datedif' but not able to get the right solution.
Please note that I am not able to share the excel as I am posting this from my office network.
However, hope, I am able to explain my requirement correctly.
Please let me know in case of any doubts.
Any help is much appreciated.
Regards,
Kaushik
I have a "Data Entry" userform which users use to input ceratin data which are getting captured in a particula sheet in the same workbook.
In the userform, there is a textbox which holds the date ("mm-dd-yyyy" format) as user selects the date from a calender(placed in this "Data Entry" userform).
I want the code to prevent users from entering any data on the form and give a message (and should close the form) if the date(on which they open the form to submit the info) > 23rd of that month.
To be more precise, IF user's input date(in other words, the date when they open the form)>23rd of that month THEN alert message should be popped up and form should be closed ELSE proceed.
[Note:So, date(23rd) should be fixed but "month" and year should change as the time progress....I am not able to make this dynamic]
I tried doing this by using 'datedif' but not able to get the right solution.
Please note that I am not able to share the excel as I am posting this from my office network.
However, hope, I am able to explain my requirement correctly.
Please let me know in case of any doubts.
Any help is much appreciated.
Regards,
Kaushik