Hi All
Please attached the workbook. In this Column B contains all the bank holidays. i want to write VBA code that will check if todays date is present in column B then display message "Bank Holiday" .
Thanks
Hi All
Please attached the workbook. In this Column B contains all the bank holidays. i want to write VBA code that will check if todays date is present in column B then display message "Bank Holiday" .
Thanks
This will return TRUE if today is holiday
Formula:
Please Login or Register to view this content.
Never use Merged Cells in Excel
Zbor, I need to write VBA code for this.
![]()
Please Login or Register to view this content.
Last edited by walruseggman; 10-08-2014 at 11:16 AM.
Thanks but can you have a look at the following code. After date1 < date 2 condition statement, I want to check if date2 is a bank holiday and if the answer is Yes then move the control to rs.moveprevious statement in green font below.
![]()
Please Login or Register to view this content.
Try:
Not sure what your rs. is, but GoTo is the syntax you want to use to go to a specific line. Also, the line you are going to needs a colon at the end of it.![]()
Please Login or Register to view this content.
I tried it but didn't work. Can anyone please help me how to use Goto statement. Thanks
STill stuck in the same problem . if its a bank holiday then move focus to rs.moveprevious line and skip all the steps before this line.
hope anyone can help me in this.
![]()
Please Login or Register to view this content.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks