create a update query Form

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Is it possible to create a form to enter the values for an update query?

Thanks,

Brook
 
Yes, simply create the Update Query and use a reference to the form for the
values.

For example, create a form in NWind called UpdateExampleForm.
Add 2 text boxes, NewName and EmpID
Stick in 1 for Emp ID and "Jane" for New Name

Run the following to demonstrate using the form for both criteria and values

UPDATE Employees SET Employees.FirstName =
[forms]![UpdateExampleForm]![NewName]
WHERE (((Employees.EmployeeID)=[forms]![UpdateExampleForm]![EmpID]));

You should see Nancy Davolio change to Jane Davolio
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top