Running a query with information in a continuous subform

  • Thread starter Thread starter Turner.John.P
  • Start date Start date
T

Turner.John.P

All,

I have a continuous subform that displays a list of contacts
associated with a department. I am trying to allow the user to mark an
individual conact for deletion. Right now I have a command button in
place that check performs a simple check and then opens an append
query. I am trying to pull the individuals information from the
continuous subform, but the query asks me to input the values. The
fields are defined in the query as Forms![FormName]![FieldName]. Is
there a way to do this?

Thank you,

John
 
You have to tell it the form and subform like this ---
Forms![FormName]![SubFormName]![FieldName]
You will also need to somehow limit it to the one record you want to append.

An easier way is to add a Yes/No field to mark the records for archive and
have your subform query only pull records that are not marked - therefore no
appending or deleting. The information is always available in the one table.
 
All,

I have a continuous subform that displays a list of contacts
associated with a department. I am trying to allow the user to mark an
individual conact for deletion. Right now I have a command button in
place that check performs a simple check and then opens an append
query. I am trying to pull the individuals information from the
continuous subform, but the query asks me to input the values. The
fields are defined in the query as Forms![FormName]![FieldName]. Is
there a way to do this?

Thank you,

John

Because the form in question is a subform, your syntax needs to be:

Forms![Main Form Name]![Subform Control Name].Form![Field Name]
 
Back
Top