J
James Lee
Hello,
I have a form in Word that has 3 different comboboxes. In order to
get each item onto the combobox/drop down list I put in this code:
Private Sub UserForm_Initialize()
ComboBox1.ColumnCount = 1
'Load data into ComboBox
ComboBox1.List() = Array(" ", "Content Room A", "Content Room B",
"Content Room C", "Content Rooms AB", "Content Rooms BC", "Content
Rooms ABC")
ComboBox2.ColumnCount = 1
'Load data into ComboBox
ComboBox2.List() = Array(" ", "Conference", "Classroom", "Lecture",
"Horseshoe")
ComboBox3.ColumnCount = 1
'Load data into ComboBox
ComboBox3.List() = Array(" ", "CORP", "ESPN3", "DISNEY")
End Sub
No matter how may times I save the document or anything, when I close
the document and reopen it or send it to someone it won't recognize
the code so the drop down/comboboxes show up as empty. Any Ideas?
Also, I have a command button that i have that when it is clicked it
opens a new mail message in Outlook with the Word document already
attached. Is there a way to make it do that as well as inputing the
"TO" email address automatically?? The code I have for the command
button already is this:
Private Sub CommandButton1_Click()
Application.Options.ButtonFieldClicks = 1
Options.SendMailAttach = True
ActiveDocument.SendMail
End Sub
Thanks for any help.
Joe
I have a form in Word that has 3 different comboboxes. In order to
get each item onto the combobox/drop down list I put in this code:
Private Sub UserForm_Initialize()
ComboBox1.ColumnCount = 1
'Load data into ComboBox
ComboBox1.List() = Array(" ", "Content Room A", "Content Room B",
"Content Room C", "Content Rooms AB", "Content Rooms BC", "Content
Rooms ABC")
ComboBox2.ColumnCount = 1
'Load data into ComboBox
ComboBox2.List() = Array(" ", "Conference", "Classroom", "Lecture",
"Horseshoe")
ComboBox3.ColumnCount = 1
'Load data into ComboBox
ComboBox3.List() = Array(" ", "CORP", "ESPN3", "DISNEY")
End Sub
No matter how may times I save the document or anything, when I close
the document and reopen it or send it to someone it won't recognize
the code so the drop down/comboboxes show up as empty. Any Ideas?
Also, I have a command button that i have that when it is clicked it
opens a new mail message in Outlook with the Word document already
attached. Is there a way to make it do that as well as inputing the
"TO" email address automatically?? The code I have for the command
button already is this:
Private Sub CommandButton1_Click()
Application.Options.ButtonFieldClicks = 1
Options.SendMailAttach = True
ActiveDocument.SendMail
End Sub
Thanks for any help.
Joe