Word doc in listbox
I have created a UserForm with a ComboBox(ComboBox3) and a ListBox(ListBox5).
The ComboBox has several entries in it (ie. 1 2 3 4 5 ...). If I choose 2 I
would like the ListBox to automatically be populated with a specified Word
document.
I'm calling this procedure after I have made my chioce in the ComboBox, this
procedure displays the word document but not in the listbox. It stats a
seperate window with the document displayed. I want to have the file show up
in the listbox as read only.
Sub ListBox5_update()
Set oWord = CreateObject("Word.Application")
oWord.Visible = True
Set WORDObject = oWord.Documents.Open("C:\file.doc")
End Sub
Any help would greatly be appreciated
|