473,388 Members | 1,230 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,388 software developers and data experts.

Access to auto populate a date in field2 once field one is populated

Hi: I have two fields, First follow up date sent email. I want the second field, Second follow up date sent email, to auto populate seven days into the future. this is on a Access form. How and where would the expression be placed in which field first follow up or second followup field. On the table or the form
Aug 21 '17 #1

✓ answered by PhilOfWalton

Pure Guess: I would have thought you would have updated the First Field and calculate the second from it, in which case the code should be

Expand|Select|Wrap|Line Numbers
  1. Me!SecondDate = DateAdd("d",7, Me!FirstDate)
  2.  
Sorry can't be bothered with your 35 letter field definitions. I'm a rotten typist.

Phil

7 1906
NeoPa
32,556 Expert Mod 16PB
On the Form. In the AfterUpdate Event Procedure of the control where the first field is managed.
Aug 22 '17 #2
Thanks you I keep getting a syntax error
me.First_Follow_Up_Date_on_Email_7_days = DATEADD("d",7,Me.Second_follow_up_Date_on_Email)
Aug 22 '17 #3
NeoPa
32,556 Expert Mod 16PB
I see no obvious syntax error. Perhaps it would make sense to post the exact error message and number along with the code of the whole procedure this error is thrown up within.

Please don't forget to use the [CODE] tags when posting code as that's a site requirement. Every posting window has a button to add them to any selected text for you.
Aug 22 '17 #4
Hi Thanks for replying...
the error now reads;
The expression After Update you entered as the event property setting produced the following error; Invalid outside procedure.
*the expression may not result in the name of a macro, the name of a user-defined function, or [event procedure].
*there may have been an error evaluating the function, event or macro
Aug 22 '17 #5
PhilOfWalton
1,430 Expert 1GB
Pure Guess: I would have thought you would have updated the First Field and calculate the second from it, in which case the code should be

Expand|Select|Wrap|Line Numbers
  1. Me!SecondDate = DateAdd("d",7, Me!FirstDate)
  2.  
Sorry can't be bothered with your 35 letter field definitions. I'm a rotten typist.

Phil
Aug 22 '17 #6
NeoPa
32,556 Expert Mod 16PB
Please refer back to my last post where I suggest you give the error message and number, along with the code of the whole procedure. One without the other adds very little to our understanding.

PS. The error message already posted indicates this is something quite different from a syntax error. Please try to be accurate with your information. That is critical. It avoids sending us off on wild-goose chases.
Aug 23 '17 #7
Thank you , that was the issue I should have flipped the fields around.
Aug 23 '17 #8

Sign in to post your reply or Sign up for a free account.

Similar topics

5
by: joshua.nicholes | last post by:
I have an access database that consists of two tables.A data collection table and a species list table. The data collection table has about 1500 records in it and the species list has about 600....
4
by: whamo | last post by:
I have the need to populate a field based on the selection in a combo box. Starting out simple. (2) tables tbl_OSE_Info and tbl_Input; tbl_OSE_Info has three fields: Key, OSE_Name and OSE_Wt...
6
by: awojciehowski | last post by:
I am working with a database now and need some guidance. I am attempting to input an auto calculation. I have the ability to enter a date in a text box on a form. I want to be able to have...
2
by: Ronald | last post by:
I hope somebody can help. I can't get into the specifics of my project, but I'll try to create a simple example: tblVehicle * VIN (text box) * Make (text box) * Model (text box) frmRepair
2
by: paulyXvpf | last post by:
Hi All, FACTS: > I've created a VB.NET 2005 form, with a SQL Server 2000 backend > The form has about 30 fields that populate 30 columns in the SQL database > The form has mostly text feilds,...
9
by: yappy77 | last post by:
I want my "requalify date" to auto populate to the beginning of the month in the following year when my "liability date" gets entered/changed. Example: Liablity date = 11/15/2010; 7/31/2011 ...
1
by: Jo Fidler | last post by:
I am building a database and when a field is populated I would like another field to automatically insert the date/time. I have a date/time stamp field for when the record is created but would...
5
by: jamtakjohn | last post by:
I am fairly new to Access and in particular to Access 2013. I have created a database that uses a table to store information about students, including two multiple select fields. I have then used...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.