working day date diff

Public Schedule Face-to-Face & Online Instructor-Led Training - View dates & book

Forum home » Delegate support and help forum » Microsoft Access Training and help » Working day date diff

Working day date diff

resolvedResolved · Medium Priority · Version 2003

Jason has attended:
Access Advanced course
Access VBA course

Working day date diff

I am struggling to find a way of calulating the number of working days between a fixed date and the current date

Thanks in advance

Jason

Edited on Tue 16 Sep 2008, 12:03

RE: working day date diff

Hi Jason

The DateDiff function doesn

RE: working day date diff

That worked well thanks!

I've got the following code to work to open a restricted form called FrmInternalStaffPrivate which is linked to the original form where the command button is located. Problem is that it opens at the first record and not the related record like a sub form would.

What code do I need to add and where?

Cheers

Jason

-------------------------------------------------------

Private Sub cmdOpenFrmInternalStaffPrivate_Click()

'Attached to On Click event of cmdFrmInternalStaffPrivate

Dim strPasswd

strPasswd = InputBox("Enter Password", "Restricted Information")

'Check to see if there is any entry made to input box, or if
'cancel button is pressed. If no entry made then exit sub.

If strPasswd = "" Or strPasswd = Empty Then
MsgBox "No Input Provided", vbInformation, "Required Data"
Exit Sub
End If

'If correct password is entered open InternalStaffPrivate form
'If incorrect password entered give message and exit sub

If strPasswd = "Password" Then
DoCmd.OpenForm "FrmInternalStaffPrivate", acNormal
Else
MsgBox "Sorry, you do not have permission to access this information", _
vbOKOnly, "Important Information"
Exit Sub
End If
End Sub


 

Access tip:

Action queries

Unlike select queries you cannot use action queries as a data source for the use with forms or reports,as they do not return a dataset that can be read.

View all Access hints and tips


Server loaded in 0.09 secs.