add name to telephone calls logged

samson

New member
Local time
Today, 08:40
Joined
Sep 7, 2003
Messages
7
I'm trying to add the customer's name to calls logged by Samsung software.
When a call starts a DDE is sent to form [log], to filter on phone number.
Once the telephone call is finished, a new record is sent to an access file table[log]. I then want to send the name of the customer to the new record in table [log]. I can not access the Samsung software. Using form [log] to edit the record is no good cos, it's only updated once it's closed and re-opened.

Something like this:
Private Sub Form_Current()

Dim db As Database
Dim rec As Recordset
Set db = CurrentDb()
Set rec = db.OpenRecordset("Log")

If IsLoaded("Orders By Customer") Then
If Forms![Orders By Customer].RecordsetClone.RecordCount > 0 Then
rec.movelast
Me.RecordsetClone.Bookmark = Me.Bookmark
'if the call was sent to from [log], I could use,if me.newrecord
'what is the equivalent in tables ???
If Rec.recordcount > Me.Bookmark Then

rec.MoveLast
rec.Edit
rec![name] = Me![ContactLastName]
rec![CustomerID] = Me![CustomerID]
rec.Update

DoCmd.Close acForm, "Log"
End If
End If
End If

Simon
 

Users who are viewing this thread

Back
Top Bottom