After Update Event

M

Ms-Exl-Learner

After Update Event

Hi All,

I am having a table like the below:-

Table Name : DCData

Field Name Type
Document Presented Yes/No
Date Date/Time

I have created a form Using Wizard and get the fields from DCdata Table to
my form.

Form Name: DCData (F)

I require a after update event macro for my [Document Presented] field
(Yes/No) if the person check the [Document Presented] check box then the form
should show the [Date] field otherwise if it is unchecked then the [Date]
field should not be visible and cannot be accessed by the users. (Using
Access 2003)

Awaiting for your reply.
 
A

Arvin Meyer [MVP]

I don't write macros, but here's some VBA code:

Private Sub Document_Presented_AfterUpdate()
If Me.[PDocument Presented] = True Then
Me.[Date].Visible = True
Else
Me.[Date].Visible = False
End If
End Sub

You will also need to use similar code in the form's current event.
 
M

Ms-Exl-Learner

Thank you very much!!!

--------------------
(Ms-Exl-Learner)
--------------------


Arvin Meyer said:
I don't write macros, but here's some VBA code:

Private Sub Document_Presented_AfterUpdate()
If Me.[PDocument Presented] = True Then
Me.[Date].Visible = True
Else
Me.[Date].Visible = False
End If
End Sub

You will also need to use similar code in the form's current event.
--
Arvin Meyer, MCP, MVP
http://www.datastrat.com
http://www.accessmvp.com
http://www.mvps.org/access


Ms-Exl-Learner said:
After Update Event

Hi All,

I am having a table like the below:-

Table Name : DCData

Field Name Type
Document Presented Yes/No
Date Date/Time

I have created a form Using Wizard and get the fields from DCdata Table to
my form.

Form Name: DCData (F)

I require a after update event macro for my [Document Presented] field
(Yes/No) if the person check the [Document Presented] check box then the
form
should show the [Date] field otherwise if it is unchecked then the [Date]
field should not be visible and cannot be accessed by the users. (Using
Access 2003)

Awaiting for your reply.


.
 
N

nieves o. marberry

Ms-Exl-Learner said:
After Update Event

Hi All,

I am having a table like the below:-

Table Name : DCData

Field Name Type
Document Presented Yes/No
Date Date/Time

I have created a form Using Wizard and get the fields from DCdata Table to
my form.

Form Name: DCData (F)

I require a after update event macro for my [Document Presented] field
(Yes/No) if the person check the [Document Presented] check box then the
form
should show the [Date] field otherwise if it is unchecked then the [Date]
field should not be visible and cannot be accessed by the users. (Using
Access 2003)

Awaiting for your reply.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top