updating a record

  • Thread starter Thread starter john fox
  • Start date Start date
J

john fox

Hello there, Is there a way of updating a record in a
recordset opened in a form (Say form A) from another form
(Say form B)?
 
Hello there, Is there a way of updating a record in a
recordset opened in a form (Say form A) from another form
(Say form B)?

Only by updating the underlying table and requerying FormA. This may
fail because the record is already open for editing. What's the
context?
 
john fox said:
Hello there, Is there a way of updating a record in a
recordset opened in a form (Say form A) from another form
(Say form B)?

I've had luck with this:


If IsOpen("FormA") then
[Forms]![FormA].Field1= Me.MyField1
End If

But I'm not sure exactly what you want to do.

Jack
 
-----Original Message-----


Only by updating the underlying table and requerying FormA. This may
fail because the record is already open for editing. What's the
context?



.
FormA opens a recordset and displays some of its fields,
which are not to be altered by a user. However, I would
like the user to change or add to some of the fields of
the recordset and I crerated another form (FormB) that
would allow the user to do this. The user will access this
data entry functionality only after querying on the first
form and clicking a command button. To do this I have
declared the recordset variable as "PUBLIC". This is where
the problem begins.

When FormB opens it is sought that it picks up a few
fields from the current record in the recordset to
populate a few of its fields as its header. But, as soon
as I hit the command button that should open FORMB, I end
up in "Error 464 message: object required". And the
debugger points to the first assignment statement code
behind "FORMB".

child_form.frmTenant = mrstlocalctx!tenant ' this_tenant
 
When FormB opens it is sought that it picks up a few
fields from the current record in the recordset to
populate a few of its fields as its header. But, as soon
as I hit the command button that should open FORMB, I end
up in "Error 464 message: object required". And the
debugger points to the first assignment statement code
behind "FORMB".

child_form.frmTenant = mrstlocalctx!tenant ' this_tenant

Without knowing anything about what child_form or frmTenant or
mrstlocalctx ARE, I can't even speculate about what this statement is
trying to accomplish.
 
Back
Top