box (lstProtect) of which is multichoice. Depending on which basic
descriptions are chosen in the list box i.e. Ducts, Freeformat etc, I wish a
more elaborate description of the choice inserted in a textbox(txtProtect),
based on a case statement of the list index of the list box.(only two
choices so far but more to be added.)
With the help of this forum, I've been able to put the lstProtect choices in
the text box but not the more elaborate descriptions.
Code so far is as below.
Private Sub lstProtect_Change()
Dim Workstring
Dim Userchoice As Long
Userchoice = lstProtect.ListIndex
Select Case Userchoice
Case 0
txtProtect.Text = "It will be necessary for you to install ***
number spare ducts.(Please refer to ""STORES"" section Specific Conditions)"
Case 1
txtProtect.Text = "Please replace this text with your own"
End Select
' Set Workstring empty
Workstring = ""
' Items are indexed from zero
' Loop through all the items..
For i = 0 To lstProtect.ListCount - 1
n = i + 1
'..and check whether each is selected
If lstProtect.Selected(i) Then
Workstring = Workstring & lstProtect.List(i) & "." &
Chr(10)
End If
Next i
txtProtect.Value = Workstring
End Sub
I would be grateful for any assistance in achieving my goal above.
TIA

Signature
Al@n
--
Al@n
Doug Robbins - Word MVP - 20 Nov 2006 04:15 GMT
See response to your later post.

Signature
Hope this helps.
Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.
Doug Robbins - Word MVP
> box (lstProtect) of which is multichoice. Depending on which basic
> descriptions are chosen in the list box i.e. Ducts, Freeformat etc, I wish
[quoted text clipped - 40 lines]
>
> TIA