enter value from textbox on form into another form on close

F

Fipp

I have 2 forms open.
the first form which is open in the background is called "main"
The "main" form has a textbox called [formationid]

The second form which is open on top and visible is called "formation" it
also has a textbox called [formationid]

I am trying to get it so that when I look up the record in "formation" and
then close the form the value in [formationid] on the formation form is then
entered into the textbox [formationid] in the "main" form.
 
D

Dennis

In the On close event of your formation form put this
[Forms]![Main]![formationid] = Me.formationid
 
F

Fipp

Dennis,
Thanks that works great except when the [formationid] field on the main form
already has a value it won't override the previous value with the new one.

Dennis said:
In the On close event of your formation form put this
[Forms]![Main]![formationid] = Me.formationid

Fipp said:
I have 2 forms open.
the first form which is open in the background is called "main"
The "main" form has a textbox called [formationid]

The second form which is open on top and visible is called "formation" it
also has a textbox called [formationid]

I am trying to get it so that when I look up the record in "formation" and
then close the form the value in [formationid] on the formation form is then
entered into the textbox [formationid] in the "main" form.
 

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

Top