Autopopulated data changes saved to new record

G

Guest

I have a patient database with a table of about 50 prewritten treatment plans
that will be used as a starting point by the therapist when creating a plan
for each patient. What we want to do is open the treatment plan in a subform,
customize the plan and then save the plan to another table assigned to the
patient and to not override the original prewritten plans. What is the best
way to approach this? Any ideas? Thanks!
 
A

Arvin Meyer [MVP]

I use a combobox and a textbox superimposed upon it. With the combo's down
arrow in view, choose the treatment plan. In the afterupdate event of the
combo box, push the data into the text box. Something like:

Private Sub cboTreatment_AfterUpdate()

Me.txtTreatment = Me.cboTreatment.Column(1)
Me.txtTreatment .SetFocus

End Sub

Column(1) is actually the second column of the combo box (the first being
column(0)). cboTreatment is the combo which normally lives on top of the
text box:
txtTreatment .
 
G

Guest

Thank you. This is most helpful

Arvin Meyer said:
I use a combobox and a textbox superimposed upon it. With the combo's down
arrow in view, choose the treatment plan. In the afterupdate event of the
combo box, push the data into the text box. Something like:

Private Sub cboTreatment_AfterUpdate()

Me.txtTreatment = Me.cboTreatment.Column(1)
Me.txtTreatment .SetFocus

End Sub

Column(1) is actually the second column of the combo box (the first being
column(0)). cboTreatment is the combo which normally lives on top of the
text box:
txtTreatment .
--
Arvin Meyer, MCP, MVP
http://www.datastrat.com
http://www.mvps.org/access
http://www.accessmvp.com
 

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