macgerailt
MIS
I am no expert in access so I need some help with the above.
I have developed a form for outbound telesales. This form is polulated by means of a query which queries a table -based on whether a phone Num exists and call outcome is not populated.
What I am trying to do is to datestamp a field in the table called date_ofcall with the date the call took place when the operator has completed the call and moves to the next record.
All other elements are updated back to the table correctly from the form- once the call has been completed and next record selected
I have tried two approaches - setting up an event procedure before_update called date of call - see below:
version1
Private Sub dateofcall_BeforeUpdate()
Dim callback_date
Set callback_date = date
End Sub
I then tried to use a Macro to populate the date on next rec
using the date() function as follows:
IsNull([Date_ofcall]) --> go to control source
... ---> RunCode
This Macro is run when the next record command box is selected. Otehr elements of the macro work but the date part doesn't
I have also setting the update of table containing the date_ofcall field to date() and this doesn't work either nor does the time update .
'RS!Date_OfCall = Forms!callsmade2!date_ofcall
'RS!TimeOfCall = Time ()
I have checked that the control source in the from is updating the correct field in the table (see above).
I have scoured previous threads to find similar problems but could'nt find (maybe understand )a solution that would work for me.
Please try to make the responses idiot proof as I am not vb prodicient.
Also how can I implement record locking on the form so that all operators are not accessing the same records?
Thanks
I have developed a form for outbound telesales. This form is polulated by means of a query which queries a table -based on whether a phone Num exists and call outcome is not populated.
What I am trying to do is to datestamp a field in the table called date_ofcall with the date the call took place when the operator has completed the call and moves to the next record.
All other elements are updated back to the table correctly from the form- once the call has been completed and next record selected
I have tried two approaches - setting up an event procedure before_update called date of call - see below:
version1
Private Sub dateofcall_BeforeUpdate()
Dim callback_date
Set callback_date = date
End Sub
I then tried to use a Macro to populate the date on next rec
using the date() function as follows:
IsNull([Date_ofcall]) --> go to control source
... ---> RunCode
This Macro is run when the next record command box is selected. Otehr elements of the macro work but the date part doesn't
I have also setting the update of table containing the date_ofcall field to date() and this doesn't work either nor does the time update .
'RS!Date_OfCall = Forms!callsmade2!date_ofcall
'RS!TimeOfCall = Time ()
I have checked that the control source in the from is updating the correct field in the table (see above).
I have scoured previous threads to find similar problems but could'nt find (maybe understand )a solution that would work for me.
Please try to make the responses idiot proof as I am not vb prodicient.
Also how can I implement record locking on the form so that all operators are not accessing the same records?
Thanks