Darren D
darren at activebilling.com.au
Thu Sep 20 18:28:55 CDT 2007
Hi Chester
How about some thing like this
Private Sub StartDate_Exit(Cancel As Integer)
If Forms![frm Manifold Chart]!StartDate > Forms![frm ManifoldChart]!EndDate
Then
msgBox "Invalid Date. Start date must be before end date"
'Stop the Exit Event occurring
Cancel = true
'send the cursor wherever you want
Forms![frm Manifold Chart]!StartDate.setfocus
Else
'OK to go
'Do some other stuff here
end If
End Sub
Darren
-----------------
T: 0424 696 433
-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Kaup, Chester
Sent: Friday, 21 September 2007 6:40 AM
To: Access Developers discussion and problem solving
Subject: Re: [AccessD] Resume command problem
I need some way to go back and check the value in the text box again to
see if a valid value has been entered. I may be doing this all the wrong
way?
-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Susan Harkins
Sent: Thursday, September 20, 2007 3:31 PM
To: 'Access Developers discussion and problem solving'
Subject: Re: [AccessD] Resume command problem
Resume works as part of an error-handling statement/routine. In the
example
below, you don't need it.
Susan H.
I am having trouble using the resume command. Just don't have a good
understanding. Here is the code I am using with it. Just generates an
error
message of "Resume without error" What does it need to look like.
Thanks.
Private Sub StartDate_Exit(Cancel As Integer)
If Forms![frm Manifold Chart]!StartDate > Forms![frm Manifold
Chart]!EndDate Then
MsgBox "Invalid Date. Start date must be before end date"
End If
Resume
End Sub
Chester Kaup
Engineering Technician
Kinder Morgan CO2 Company, LLP
Office (432) 688-3797
FAX (432) 688-3799
No trees were killed in the sending of this message. However a large
number
of electrons were terribly inconvenienced.
--
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com
No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.5.485 / Virus Database: 269.13.19/1008 - Release Date:
9/14/2007
8:59 AM
--
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com
--
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com