Date Problem

B

Bob

I have a date Text box showing the date of a payment
Format is dd-mmm-yy
Default Value =Now()
But if I click in the box to change the date I am getting date and time
which is annoying when you only want the date
Thanks for any help ..Bob







..........Jenny Vance
 
K

Ken Snell \(MVP\)

You get this result because, when you click in the textbox, you "see" all of
the data that are there, not the formatted view. No way I know to change
this directly.

You could change the default value to
=Date()
if you just want to have the date there (no time).

Otherwise, you'd need to go with a somewhat complicated setup on the form
using one of these approaches:

1) Use a combination of two textboxes: one to display and be bound to the
actual field; the other to allow entry or editing of data. You would use
programming to move data from one textbox to the other so that it appears to
work seamlessly.

2) Change the underlying field's data type in the actual table to a text
field so that you will see whatever was typed in there. Of course, this
would mean that your queries would have to convert the text field's values
to dates if you want to use them as actual date/time data types, which is a
bit clunky.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Command Button Query 3
Date format query 7
Date Format Code 3
Control Code to set a Date 8
Combo box to control two sub forms 2
Form filter & macro 4
Date format in a report 2
inputting a date into a text box 1

Top