retrieve value from a field before delete record

irade92

Registered User.
Local time
Today, 08:21
Joined
Dec 26, 2010
Messages
229
Hi
I want to retrieve value from a certain field in a variable before i delete that record ..I need that value to find another record in another table..Please help..
Thanks
 
Please tell us more about this
a certain field in a variable

Perhaps you could give us a realistic example of exactly what you mean.
 
could you store the value in another variable rather than a field, and access it using that new variable
 
Please tell us more about this

Perhaps you could give us a realistic example of exactly what you mean.
I have a query in a subform related with main form with master and child filed for certain criteria i.e date...Also I have a button in main form to delete what ever record...Fist I choose a record from subform and then click on button to delete it..I use this code:
If (Not Form.NewRecord) Then

intAnswer = MsgBox("Are u sure", vbYesNo + vbQuestion, "Delete record")

If intAnswer = vbYes Then

DoCmd.RunCommand acCmdDeleteRecord
Else
DoCmd.RunCommand acCmdUndo
End If

End If

If (Form.NewRecord And Not Form.Dirty) Then
Beep
End If

If (Form.NewRecord And Form.Dirty) Then
DoCmd.RunCommand acCmdUndo
End If
and this work fine....I want to retrieve some value from this record before I delete it i.e like Id and DATE so I can find that value in another table to delete another record..
 

Users who are viewing this thread

Back
Top Bottom