View Single Post
  #3  
Old May 5th, 2008, 01:23 PM posted to microsoft.public.access.forms
Charles via AccessMonster.com
external usenet poster
 
Posts: 19
Default DLookUp in a form

Thank you.
Your variation of DLookUp works fine. This will allow me to delete 6 bottons
and 6 queries.

Thanks again

Charles

Douglas J. Steele wrote:
What exactly are you looking for? If ServDate contains a date, you can
determine the name of the day using

=Format(Me![ServDate], "ddd") (for Sun, Mon, Tue,...)

or

=Format(Me![ServDate], "dddd") (for Sunday, Monday, Tuesday,...)

As to why your DLookup didn't work, you need to ensure that you're passing a
value, not a reference. In other words, you need

DLookUp("[Day_Txt]","tbl_Day",Weekday(ServDate) & "=[Day_Nr]")

I have a form that I use for control buttons, I created a text box to enter
the date used by an append query to create a table for work schedules. I

[quoted text clipped - 12 lines]
Thanks
Charles


--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...forms/200805/1