Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / General 2 / May 2008

Tip: Looking for answers? Try searching our database.

Show Date Question

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Bob V - 24 Jan 2008 08:08 GMT
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
Allen Browne - 24 Jan 2008 08:25 GMT
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.

Signature

Allen Browne - Microsoft MVP.  Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

> 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 - 24 Jan 2008 08:53 GMT
Thanks Allen I will change it to a Text Box???.............Thanks Bob

> Set the Control Source of the combo to:
>    =IIf(([MyCheckBox]), Date(), Null)
[quoted text clipped - 5 lines]
>> show today's date if Check box is True!
>> Thanks for any Help....Bob
ENGLER FREDERIC - 03 May 2008 12:34 GMT
"Bob V" <rjvance@ihug.co.nz> a écrit dans le message de groupe de discussion
: eSNl8AmXIHA.5164@TK2MSFTNGP03.phx.gbl...
> 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
Blackstar - 04 May 2008 19:56 GMT
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
Douglas J. Steele - 04 May 2008 20:08 GMT
Except that Now includes both date and time.

Date and Now are NOT interchangable in meaning.

Signature

Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no private e-mails, please)

> Private Sub chkbox_AfterUpdate()
> If Me.chkbox = -1 Then
[quoted text clipped - 9 lines]
>
> Didier
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.