I am relatively new to using Access. Will someone please explain to me how to mirror or copy (whatever the correct terminology is)a value that is entered into a form and have it automatically mirrored or copied into another form?
I have a database with multiple entries. (i.e., one client with lots of orders) I have used forms & subforms liberally and lots of tables throughout my database with command buttons and all of that good stuff. I would like the values I enter in on a "general Information" form to be reflected automatically in all of the other forms and subforms. (i.e. I would only like to enter the information once.) I have tried to copy information to forms/subforms, write update queries, and a couple of other things to make this work. I suspect it is something simple, i just need somone to get me over the top on this one.
There are several ways to use information from one form on other forms. If you want the info you entered into one form to be entered into another form when you open it, then that could be done in the form current event.
You can use the OpenArgs property. When you open a form you can specify an argument to be sent to the form to be opened. This argument can then be captured and used in the new form, maybe in a sql query if you like. Here´s an example:
'Call the new form
DoCmd.OpenForm "frmAny", , , , acFormEdit, , bestId
'Capture the argument in the new form
bestId=Forms!frmAny.OpenArgs
'Use the argument in a query
Set dbs = CurrentDb
Set rst = dbs.OpenRecordset("SELECT * FROM TempHI WHERE bestId = " & bestId & ";"
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.