DWUTKA at marlow.com
DWUTKA at marlow.com
Wed Jun 21 16:16:26 CDT 2006
Too busy to reply offline. You have my permission.
Drew
-----Original Message-----
From: Martin Reid [mailto:mwp.reid at qub.ac.uk]
Sent: Wednesday, June 21, 2006 6:24 AM
To: Access Developers discussion and problem solving
Subject: [AccessD] OT Permissions
Folks
Some time back John Colby and I requested permission from you all to publish
some of your questions and answers in a new Access book. For various reasons
that project didnt work out. Anyway
I am almost finished writing up a new book and would like to do the same
sort of thing in the last chapter. This will only be about 20 pages of your
Q and A stuff and I would like permission to reuse some of your submissions
to the list.
If you would be kind enough to give such permissions please email me of
list. If you dont email with permissions I will know not to include anything
from you. Only those Q and As where I have specific permission to use will
be included.
Names of contributions will be added into the front page of the book
referring to that chapter.
Martin
Martin WP Reid
Training and Assessment Unit
Riddle Hall
Belfast
tel: 02890 974477
________________________________
From: accessd-bounces at databaseadvisors.com on behalf of Gustav Brock
Sent: Wed 21/06/2006 11:50
To: accessd at databaseadvisors.com
Subject: Re: [AccessD] '6a' or '6p' Are Valid Dates?
Hi Dan
Some years ago I posted a general method for situations like yours.
Apply a format string to the textbox and this code:
Private Sub txtDate_BeforeUpdate(Cancel As Integer)
' Catch invalid date entry.
With Me!txtDate
Cancel = Val(.Text) <> Val(Format(.Text, .Format))
If Cancel = True Then
DoCmd.Beep
.Undo
End If
End With
End Sub
/gustav
>>> dwaters at usinternet.com 21-06-2006 04:35 >>>
I was testing a new module and quickly typed '6a' into a date field,
expecting to get an error, but no, the table thinks it's a real date! Turns
out this will enter 6:00:00 AM 12/30/1899. Of course my customers need this
'quick entry feature'!
How can I code to trap this in my form and null the field?
Thanks!
Dan Waters
ProMation <http://www.promationsystems.com/> Systems, Inc.
--
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com <http://www.databaseadvisors.com/>