Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #8  
Old 08-18-2011, 10:55 PM
Catalin.B Catalin.B is offline Code to add dates Windows Vista Code to add dates Office 2007
Expert
 
Join Date: May 2011
Location: Iaşi, Romānia
Posts: 386
Catalin.B is on a distinguished road
Default

enter in cell B8 this formula =WEEKDAY(B7), and refer in your code to cell B8...
Now, this part of the code should work

If Not Weekday(Worksheets("SETUP").Range("B8")) = 2 Then
MsgBox "Start Date must be a Monday (week beginning)", vbInformation
Range("B7").Select
ValidateFields = True
Exit Function
End If
Reply With Quote
 

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Code to add dates Calendar without actual dates parnol01 Project 1 12-16-2015 09:30 AM
Code to add dates Calculating dates Daria11 Word VBA 1 06-08-2011 06:54 PM
Code to add dates Sequential Dates in Word Ultrap3 Word 2 02-04-2011 02:53 PM
Code to add dates Calculated dates. Ziggy-R Word 10 09-28-2010 01:42 AM
Adding dates mkkram Word 0 11-27-2006 09:18 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 07:16 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft