Show Date Question

  • Thread starter Thread starter Bob V
  • Start date Start date
B

Bob V

On my Form I have a Combo box and a check box. I want the combo box to show
today's date if Check box is True!
Thanks for any Help....Bob
 
Set the Control Source of the combo to:
=IIf(([MyCheckBox]), Date(), Null)

It's unusual to use a combo to display a date like that, so I suspect I have
not understood your question correctly.
 
Thanks Allen I will change it to a Text Box???.............Thanks Bob

Allen Browne said:
Set the Control Source of the combo to:
=IIf(([MyCheckBox]), Date(), Null)

It's unusual to use a combo to display a date like that, so I suspect I
have not understood your question correctly.

--
Allen Browne - Microsoft MVP. Perth, Western Australia

Reply to group, rather than allenbrowne at mvps dot org.

Bob V said:
On my Form I have a Combo box and a check box. I want the combo box to
show today's date if Check box is True!
Thanks for any Help....Bob
 
Bob V said:
On my Form I have a Combo box and a check box. I want the combo box to
show today's date if Check box is True!
Thanks for any Help....Bob
 
Private Sub chkbox_AfterUpdate()
If Me.chkbox = -1 Then
Me.combobox.Value = Date
Else
Me.combobox.Value = ""
End If

End Sub

instead of date you could also use Now ()
It is as you please.

Didier
 
Except that Now includes both date and time.

Date and Now are NOT interchangable in meaning.
 

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

Back
Top