Anubis3000
Programmer
Hi,
My question is in regards to record locks. Currently I have a form and subform, with corresponding tables that have a one-to-many relationship to each other.
Because of "constraints" I want to be able to lock all records currently displayed (the record on the form, and all corresponding subform records) but not the entire record source tables.
I've tried putting this code on the gotfocus event of one of my subform fields, but it doesn't work:
Dim rs As DAO.Recordset
dim rs2 as dao.recordset
Set rs = Forms!parentform.RecordsetClone
rs.Edit
set rs2 = me.recordsetclone 'me is the subform
rs2.edit
This does not work, however, as i am still able to edit subform records. Any help will be appreciated. Thnx.
My question is in regards to record locks. Currently I have a form and subform, with corresponding tables that have a one-to-many relationship to each other.
Because of "constraints" I want to be able to lock all records currently displayed (the record on the form, and all corresponding subform records) but not the entire record source tables.
I've tried putting this code on the gotfocus event of one of my subform fields, but it doesn't work:
Dim rs As DAO.Recordset
dim rs2 as dao.recordset
Set rs = Forms!parentform.RecordsetClone
rs.Edit
set rs2 = me.recordsetclone 'me is the subform
rs2.edit
This does not work, however, as i am still able to edit subform records. Any help will be appreciated. Thnx.