Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Sorry dave to get back to you on an old question.
I have the following code you sent us last week. Private Sub ComboBox1_Change() With Me.ComboBox1 If .ListIndex < 0 Then Me.TextBox3.Value = "" Else Me.TextBox3.Value = .List(.ListIndex, 1) End If End With End Sub Private Sub UserForm_Initialize() With Me.ComboBox1 .RowSource = Worksheets("list").Range("A1:B18").Address(externa l:=False) .ColumnCount = 2 .BoundColumn = 1 .ColumnWidths = "22;0" 'hide the second column End With End Sub The problem I am having now is when I select the combobox the list does not appear yet I checked all the links but I cant find what is wrong. What am I doing wrong!!!!??? -- capt |
#2
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
You sure you have something in A1:B18 of the List worksheet--especially the
column A? capt wrote: Sorry dave to get back to you on an old question. I have the following code you sent us last week. Private Sub ComboBox1_Change() With Me.ComboBox1 If .ListIndex < 0 Then Me.TextBox3.Value = "" Else Me.TextBox3.Value = .List(.ListIndex, 1) End If End With End Sub Private Sub UserForm_Initialize() With Me.ComboBox1 .RowSource = Worksheets("list").Range("A1:B18").Address(externa l:=False) .ColumnCount = 2 .BoundColumn = 1 .ColumnWidths = "22;0" 'hide the second column End With End Sub The problem I am having now is when I select the combobox the list does not appear yet I checked all the links but I cant find what is wrong. What am I doing wrong!!!!??? -- capt -- Dave Peterson |
#3
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Thanks for getting back to me.
Yes I have data down columns A and B -- capt "Dave Peterson" wrote: You sure you have something in A1:B18 of the List worksheet--especially the column A? capt wrote: Sorry dave to get back to you on an old question. I have the following code you sent us last week. Private Sub ComboBox1_Change() With Me.ComboBox1 If .ListIndex < 0 Then Me.TextBox3.Value = "" Else Me.TextBox3.Value = .List(.ListIndex, 1) End If End With End Sub Private Sub UserForm_Initialize() With Me.ComboBox1 .RowSource = Worksheets("list").Range("A1:B18").Address(externa l:=False) .ColumnCount = 2 .BoundColumn = 1 .ColumnWidths = "22;0" 'hide the second column End With End Sub The problem I am having now is when I select the combobox the list does not appear yet I checked all the links but I cant find what is wrong. What am I doing wrong!!!!??? -- capt -- Dave Peterson |
#4
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
I have just managed to get the combobox to work, it now shows the list!
But running the code I get the Debug warning with the following line high lighted in yellow: Me.TextBox3.Value = .List(.ListIndex, 1) Any ideas Dave? -- capt "capt" wrote: Thanks for getting back to me. Yes I have data down columns A and B -- capt "Dave Peterson" wrote: You sure you have something in A1:B18 of the List worksheet--especially the column A? capt wrote: Sorry dave to get back to you on an old question. I have the following code you sent us last week. Private Sub ComboBox1_Change() With Me.ComboBox1 If .ListIndex < 0 Then Me.TextBox3.Value = "" Else Me.TextBox3.Value = .List(.ListIndex, 1) End If End With End Sub Private Sub UserForm_Initialize() With Me.ComboBox1 .RowSource = Worksheets("list").Range("A1:B18").Address(externa l:=False) .ColumnCount = 2 .BoundColumn = 1 .ColumnWidths = "22;0" 'hide the second column End With End Sub The problem I am having now is when I select the combobox the list does not appear yet I checked all the links but I cant find what is wrong. What am I doing wrong!!!!??? -- capt -- Dave Peterson |
#5
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
None at all.
Are you going to share your code and the actual error message that shows up? And what did you do to get the combobox to work? I'm curious why it didn't work before. capt wrote: I have just managed to get the combobox to work, it now shows the list! But running the code I get the Debug warning with the following line high lighted in yellow: Me.TextBox3.Value = .List(.ListIndex, 1) Any ideas Dave? -- capt "capt" wrote: Thanks for getting back to me. Yes I have data down columns A and B -- capt "Dave Peterson" wrote: You sure you have something in A1:B18 of the List worksheet--especially the column A? capt wrote: Sorry dave to get back to you on an old question. I have the following code you sent us last week. Private Sub ComboBox1_Change() With Me.ComboBox1 If .ListIndex < 0 Then Me.TextBox3.Value = "" Else Me.TextBox3.Value = .List(.ListIndex, 1) End If End With End Sub Private Sub UserForm_Initialize() With Me.ComboBox1 .RowSource = Worksheets("list").Range("A1:B18").Address(externa l:=False) .ColumnCount = 2 .BoundColumn = 1 .ColumnWidths = "22;0" 'hide the second column End With End Sub The problem I am having now is when I select the combobox the list does not appear yet I checked all the links but I cant find what is wrong. What am I doing wrong!!!!??? -- capt -- Dave Peterson -- Dave Peterson |
#6
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Abit embarassing!! I never indicated what userform it was. In this case "4"
Private Sub UserForm4_Initialize() With Me.ComboBox1 .RowSource = Worksheets("list").Range("A1:B18").Address(externa l:=False) .ColumnCount = 2 .BoundColumn = 1 .ColumnWidths = "22;0" 'hide the second column End With End Sub I get a debug warning on the following code when run: Private Sub ComboBox1_Change() With Me.ComboBox1 If .ListIndex < 0 Then Me.TextBox3.Value = "" Else Me.TextBox3.Value = .List(.ListIndex, 1) End If End With End Sub The following line gets high lighted in yellow: Me.TextBox3.Value = .List(.ListIndex, 1) -- capt "Dave Peterson" wrote: None at all. Are you going to share your code and the actual error message that shows up? And what did you do to get the combobox to work? I'm curious why it didn't work before. capt wrote: I have just managed to get the combobox to work, it now shows the list! But running the code I get the Debug warning with the following line high lighted in yellow: Me.TextBox3.Value = .List(.ListIndex, 1) Any ideas Dave? -- capt "capt" wrote: Thanks for getting back to me. Yes I have data down columns A and B -- capt "Dave Peterson" wrote: You sure you have something in A1:B18 of the List worksheet--especially the column A? capt wrote: Sorry dave to get back to you on an old question. I have the following code you sent us last week. Private Sub ComboBox1_Change() With Me.ComboBox1 If .ListIndex < 0 Then Me.TextBox3.Value = "" Else Me.TextBox3.Value = .List(.ListIndex, 1) End If End With End Sub Private Sub UserForm_Initialize() With Me.ComboBox1 .RowSource = Worksheets("list").Range("A1:B18").Address(externa l:=False) .ColumnCount = 2 .BoundColumn = 1 .ColumnWidths = "22;0" 'hide the second column End With End Sub The problem I am having now is when I select the combobox the list does not appear yet I checked all the links but I cant find what is wrong. What am I doing wrong!!!!??? -- capt -- Dave Peterson -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Macro Question for Dave Peterson | Excel Discussion (Misc queries) | |||
Print question - Calling Dave Peterson! | Excel Discussion (Misc queries) | |||
Bernie, Dave, Doug, et. al. - question for you | Excel Discussion (Misc queries) | |||
Dave just one more question | Excel Discussion (Misc queries) | |||
Attn: Dave P. Question re Pix Calls via Macro | Excel Discussion (Misc queries) |