Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Insert Today's date in one field based on the value of another

Posted on 2011-03-14
4
420 Views
Last Modified: 2013-11-28
I have a tracking database and I want to make it so that when the person marks the "status" field "completed" it inputs today's date in the "datecompleted" field.  How do I do this in my form?
0
Comment
Question by:dcmennealy
  • 2
  • 2
4 Comments
 
LVL 12

Accepted Solution

by:
ErezMor earned 125 total points
ID: 35133704
you use the "AfterUpdate" event of the status field to :

if status="completed" then datecompleted=Date()

(the above is as plain as you described the scenario, meaning the status field is string that may receive the sting "completed")
0
 

Author Comment

by:dcmennealy
ID: 35133960
Thanks, it worked!
0
 

Author Closing Comment

by:dcmennealy
ID: 35134061
I am new to VBA and this was very simple and useful
0
 
LVL 12

Expert Comment

by:ErezMor
ID: 35140731
you are most welcome to ask further
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Describes a method of obtaining an object variable to an already running instance of Microsoft Access so that it can be controlled via automation.
Phishing attempts can come in all forms, shapes and sizes. No matter how familiar you think you are with them, always remember to take extra precaution when opening an email with attachments or links.
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
Using Microsoft Access, learn some simple rules for how to construct tables in a relational database. Split up all multi-value fields into single values: Split up fields that belong to other things into separate tables: Make sure that all record…

829 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question