I am trying to help my daughter's preschool staff by creating a Word document template that will make an onerous administrative task quicker and easier.
I have discovered that to get the functionality we need, I have to create a userform with visual basic. Not being a developer, I have managed to get so far with it, but just can't work out how to get it to do the last step. Basically, I want it to:
1. as the user tabs into the form text field (
bookmarked as Outcomes1), a list box (
boxOutcomes1) pops up --
this much I can do
2. in the list box is a list of criteria that the staff member will select, using
fmMultiSelectExtended --
this much I can do
3. after clicking the OK button on the pop up, the selected criteria will be inserted in the text field (
Outcomes1) --
THIS I CAN NOT WORK OUT HOW TO DO!!
Below is the code I have found works up to the point where I'm stuck. Is there anyone out here in internet-land that can help me finish this little project?
Many, many thanks for any help. Even pointing me to another forum that can help would be appreciated.
Code:
Private Sub boxOutcomes1_Change()
ActiveDocument.FormFields("Outcomes1").Result = boxOutcomes1.Text
End Sub
Private Sub UserForm_Initialize()
boxOutcomes1.List = Array("a. Separates and settles well;", "g. Openly expresses feelings;", "h. Cooperates with others;", "i. Is learning to negotiate;", "j. Makes predicted transitions smoothly;", "k. Is open to new challenges and discoveries;", "l. Celebrates and shares their contributions and achievements;", "m. Identifies and writes own name;")
End Sub