M
margaret
I'm using the report rptAppointWeekly from the CalendarReport database that
is recommended when attempting Gantt Timeline. My code on the on format is
as follows:
Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)
Dim lngTopMargin As Long
Dim lngOneMinute As Long 'size of one minute in twips
Dim datSchedStart As Date
datSchedStart = #8:00:00 AM#
lngOneMinute = 12 'number of twips in one minute
lngTopMargin = 720 'timeline starts 1/2" down in section
'create detail sections as 'layers'
Me.MoveLayout = False
Me.empName.Top = lngTopMargin + DateDiff("n", datSchedStart, Me.start) *
lngOneMinute
Me.empName.Height = DateDiff("n", Me.start, Me.end) * lngOneMinute
Me.empName.Left = (DateDiff("d", Me.WeekOf, Me.boothdate) - 1) * 1500
End Sub
I'm needing it for seven days, thus the -1)*1500 on the me.empname.left.
However, if I have a Sunday date (say 9/13/2009), I get a run time 2100.
Help, please.
Thanks.
is recommended when attempting Gantt Timeline. My code on the on format is
as follows:
Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)
Dim lngTopMargin As Long
Dim lngOneMinute As Long 'size of one minute in twips
Dim datSchedStart As Date
datSchedStart = #8:00:00 AM#
lngOneMinute = 12 'number of twips in one minute
lngTopMargin = 720 'timeline starts 1/2" down in section
'create detail sections as 'layers'
Me.MoveLayout = False
Me.empName.Top = lngTopMargin + DateDiff("n", datSchedStart, Me.start) *
lngOneMinute
Me.empName.Height = DateDiff("n", Me.start, Me.end) * lngOneMinute
Me.empName.Left = (DateDiff("d", Me.WeekOf, Me.boothdate) - 1) * 1500
End Sub
I'm needing it for seven days, thus the -1)*1500 on the me.empname.left.
However, if I have a Sunday date (say 9/13/2009), I get a run time 2100.
Help, please.
Thanks.