The following function
DateAdd("h", -24, DateAdd("d", 1, DateValue(Now)))
gives todays date without any minutes or seconds.
How is it possible by just adding 1 day and subtracting
24 hours we get todays date without time in the result.
'Now' actually displays time along with date
lulusweety
0
Newbie Poster
Recommended Answers
Jump to PostHi,
You can show only the date like this:
Dim Custom As String Custom = Now.ToString("MM/dd/yyyy") ' only date TextBox5.Text = Custom
All 2 Replies
Reply to this topic
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.