A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Using Forms
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Validating Field on basis of Field of other table



 
 
Thread Tools Display Modes
  #1  
Old December 7th, 2005, 07:46 AM posted to microsoft.public.access.forms
external usenet poster
 
Posts: n/a
Default Validating Field on basis of Field of other table

I need to ensure that user does'nt put date in credit note form which is less
than invoice no record. For X invoice, credit note date should not be lower
than invoice date.
  #2  
Old December 7th, 2005, 12:29 PM posted to microsoft.public.access.forms
external usenet poster
 
Posts: n/a
Default Validating Field on basis of Field of other table

You can set a validation rule:

[Forms]![FormName]![Invoice Date]


Note: You'll need to set one in the form's Before Update event as well (or
perhaps instead) because they may enter the invoice first (aircode):

Sub Form_BeforeUpdate(Cancel As Integer)
If Me.[InvoiceDate] Me.[Credit Note Date] Then
MsgBox "No way, Jose", vbOKOnly, "NO! Bananna"
Cancel = True
End If
End Sub
--
Arvin Meyer, MCP, MVP
Microsoft Access
Free Access downloads
http://www.datastrat.com
http://www.mvps.org/access

"Sandy" wrote in message
...
I need to ensure that user does'nt put date in credit note form which is

less
than invoice no record. For X invoice, credit note date should not be

lower
than invoice date.



 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Help with relationship plase Rock General Discussion 5 July 4th, 2005 03:54 AM
Access combo box-show name, not ID, in table? write on New Users 30 April 30th, 2005 09:11 PM
Table Design A. Williams Database Design 3 April 29th, 2005 07:02 PM
Design help, please SillySally Using Forms 27 March 6th, 2005 04:11 AM
Here's a shocker Mike Labosh General Discussion 2 October 26th, 2004 05:04 PM


All times are GMT +1. The time now is 06:33 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.