hi,
i want to know if this is possible..
i had a timestamp of
12/29/11 03:20 PM
then i want to add 5 minutes breaktime
this will become
12/29/11 03:25 PM
REM ***** BASIC *****
option explicit
Sub AddTime(oEvent as object)
' Bind to button
dim oButton
dim oForm
const sFieldName="tijd"
dim iIndex
dim TimeValue
oButton=oEvent.source.model
oForm=oButton.parent
iIndex= oForm.findcolumn(sFieldName)
select case "Datestruc"
case "Datestruc"
TimeValue=oForm.getTimestamp(iIndex)
TimeValue.minutes=TimeValue.minutes+ 5 ' add 5 minutes
oForm.updateTimestamp(iIndex,TimeValue)
case "DatesDouble" ' wit a double value
TimeValue=oForm.getdouble(iIndex)
TimeValue=TimeValue+timeserial(0,5,0) ' add 5 minutes
oForm.updatedouble(iIndex,TimeValue)
end select
End Sub
Users browsing this forum: No registered users and 7 guests