[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now


Need weekday name in ACCESS 2003 with VBA

Posted on 2012-09-21
Medium Priority
Last Modified: 2012-09-21
It seems taht the WeekdayName function does not work in ACCESS 2003 vba.  what I need is the WeekdayName and then the date but the below does not work.

dteDate = WeekdayName(Weekday(Date - i)) & " " & Format(Date - i, "mmmm dd, yyyy")

Question by:ssmith94015
LVL 120

Assisted Solution

by:Rey Obrero (Capricorn1)
Rey Obrero (Capricorn1) earned 1000 total points
ID: 38422173
dteDate = Format(Weekday(Date - i),"dddd") & " " & Format(Date - i, "mmmm dd, yyyy")

if you want abbreviated

dteDate = Format(Weekday(Date - i),"ddd") & " " & Format(Date - i, "mmmm dd, yyyy")
LVL 52

Accepted Solution

Gustav Brock earned 1000 total points
ID: 38422576
What you need is not dteDate but strDate (as String) and then:

strDate = Format(Date - i, "dddd mmmm dd, yyyy")


Author Closing Comment

ID: 38423419
I actually wound up using both - the date for a calculation and the string for formatting.

Featured Post

Prep for the ITIL® Foundation Certification Exam

December’s Course of the Month is now available! Enroll to learn ITIL® Foundation best practices for delivering IT services effectively and efficiently.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes a method of delivering Word templates for use in merging Access data to Word documents, that requires no computer knowledge on the part of the recipient -- the templates are saved in table fields, and are extracted and install…
Windows Explorer lets you open cabinet (cab) files like any other folder. In VBA you can easily handle normal files and folders, but opening and indeed creating cabinet files takes a lot more - and that's you'll find here.
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…

873 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question