Solved

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

Posted on 2011-03-14
4
417 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

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

I see at least one EE question a week that pertains to using temporary tables in MS Access.  But surprisingly, I was unable to find a single article devoted solely to this topic. I don’t intend to describe all of the uses of temporary tables in t…
A simple tool to export all objects of two Access files as text and compare it with Meld, a free diff tool.
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

705 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

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now