|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Getting mult resps. selected in listbox to concatenate & paste at a bookmark in Word
Hey, Everyone,
I'm a bit stuck and I'm hoping someone can get me to my next step. I have a MS Word template that uses a Userform with a Listbox on it. I have the code down to get the userform and listbox to appear with the possible selections. Where I'm falling down is how to use a command button (Select) so the user may select his/her responses and have them concatenate and paste into the Word document at a prescribed bookmark. Here is the code that I am currently using. I've highlighted in red the part where I am stuck. I do not know what code to put where I've left a question mark: Private Sub CmdSelect1_Click() Dim BM1a1 As Range Set BM1a1 = ActiveDocument.Bookmarks("BM1a1").Range BM1a1.Text = ?WhatCodeDoIPutHere? Me.Repaint UF1a.Hide End Sub Private Sub LB1a_Click() End Sub Private Sub UserForm_Initialize() With LB1a .AddItem "Teacher’s plans and practice indicate some awareness of prerequisite relationships, although such knowledge may be inaccurate or incomplete." .AddItem "Teacher’s plans and practice reflect a limited range of pedagogical approaches to the discipline or to the students." .AddItem "Teacher displays solid knowledge of the important concepts in the discipline and how these relate to one another." .AddItem "Teacher’s plans and practice reflect accurate understanding of prerequisite relationships among topics and concepts." .AddItem "Teacher’s plans and practice reflect familiarity with a wide range of effective pedagogical approaches in the discipline." .AddItem "Teacher displays extensive knowledge of the important concepts in the discipline and how these relate both to one another and to other disciplines….." .AddItem "Teacher’s plans and practice reflect understanding of prerequisite relationships among topics and concepts and a link to necessary cognitive structures by students to ensure understanding….." .AddItem "Teacher’s plans and practice reflect familiarity with a wide range of effective pedagogical approaches in the discipline, anticipating student misconceptions….." .AddItem "" End With lbl_Exit: Exit Sub End Sub I've attached the MS Word form, as well. Any help would be appreciated! Thanks, Mark Last edited by marksm33; 02-07-2014 at 06:37 PM. |
#2
|
|||
|
|||
No code and no attached.
|
#3
|
|||
|
|||
Here is the Code and the Attachment...Sorry.
Private Sub CmdSelect1_Click()
Dim BM1a1 As Range Set BM1a1 = ActiveDocument.Bookmarks("BM1a1").Range BM1a1.Text = ?WhatCodeDoIPutHere? Me.Repaint UF1a.Hide End Sub Private Sub LB1a_Click() End Sub Private Sub UserForm_Initialize() With LB1a .AddItem "Teacher’s plans and practice indicate some awareness of prerequisite relationships, although such knowledge may be inaccurate or incomplete." .AddItem "Teacher’s plans and practice reflect a limited range of pedagogical approaches to the discipline or to the students." .AddItem "Teacher displays solid knowledge of the important concepts in the discipline and how these relate to one another." .AddItem "Teacher’s plans and practice reflect accurate understanding of prerequisite relationships among topics and concepts." .AddItem "Teacher’s plans and practice reflect familiarity with a wide range of effective pedagogical approaches in the discipline." .AddItem "Teacher displays extensive knowledge of the important concepts in the discipline and how these relate both to one another and to other disciplines….." .AddItem "Teacher’s plans and practice reflect understanding of prerequisite relationships among topics and concepts and a link to necessary cognitive structures by students to ensure understanding….." .AddItem "Teacher’s plans and practice reflect familiarity with a wide range of effective pedagogical approaches in the discipline, anticipating student misconceptions….." .AddItem "" End With lbl_Exit: Exit Sub End Sub |
#4
|
|||
|
|||
Any update
marksm33 how did you go with doing sorting this one out??
|
Tags |
concatenate, list box, multiselection |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Concatenate function for displaying numbers in words | officeboy09 | Excel | 13 | 08-09-2021 12:59 PM |
How to use an ActiveX Control to insert a multi select listbox in Word | marksm33 | Word | 2 | 01-29-2014 05:21 PM |
Multi-select listbox help | gvibe@hotmail.com | Word VBA | 1 | 07-19-2013 10:54 AM |
as the return value of another column, using Listbox? | marreco | Excel Programming | 1 | 03-27-2012 12:48 PM |
If, move and concatenate in VBA | devcon | Excel Programming | 0 | 07-04-2011 12:44 AM |