Hi Dave,
The following is a procedure that is based on the items in the first
dropdown being stored one per row in the first column of a table and the
items for the second dropdown that correspond to the items in the first
dropdown, being stored in the adjacent cell, one per paragraph.
Dim sourcedoc As Document, i As Long, myitem As Range
' Modify the path in the following line so that it matches where you saved
Suppliers.doc
Set sourcedoc = Documents.Open(FileName:="d:\worddocs\Suppliers.doc")
For i = 1 To sourcedoc.Tables(1).Cell(Company.ListIndex + 2,
2).Range.Paragraphs.Count
Set myitem = sourcedoc.Tables(1).Cell(Company.ListIndex + 2,
2).Range.Paragraphs(i).Range
myitem.End = myitem.End - 1
SalesRep.ADDITEM myitem.Text
Next i
sourcedoc.Close SaveChanges:=wdDoNotSaveChanges
Note This code is for use with comboboxes on a userform.
Please post any further questions or followup to the newsgroups for the
benefit of others who may be interested. Unsolicited questions forwarded
directly to me will only be answered on a paid consulting basis.
Hope this helps
Doug Robbins - Word MVP
I want to be able to add items dynamically to a drop down depending on what
item was selected in the previous one
I need full code
David Legg