Hi,
I am trying to write a macro for a word document that when the word document opens it will perform one of four actions based on what is selected in an Excel userform combobox.
I can't figure out how to reference the Excel workbooks userform combobox.
For when the Word document opens I tried to write the following code to reference the Excel userform's combobox but it doesn't work:
Code
If Workbooks("Book 1.xls").Userform1.Combobox1.Text = "Blue" Then
Call Turnallbackroundsblue
end if
How do I reference an excel userform using vba for word?
If there is no way this can be done can someone let me know so I can try to set my project up a different way.
Thank you in advance.