Hi All,
I have a userform(DelForm) with a combobox(cbDelAssociate). I am loading the combo box with a list of names from a table on a worksheet("2015"). With this code:
The table starts on row 3.
This loads the names just fine but it takes a long time.
I have tried tweaking it but I can't seem to speed it up at all. Is this the wrong approach for what I am doing?
I use this code when the "Delete" button on the userform is clicked:
This code works excellent and is instantaneous.
Then I call the code to load the combobox again (it takes forever again) but the name that was deleted still appears even though it has been removed from the Table.
So I am asking can one of you Gurus help me speed up the loading of the ComboBox. And remove the deleted name from the ComboBox after its removed from the table.
Thank you in advance. You have already helped me more than you know.
D-Dog<o
></o
>
I have a userform(DelForm) with a combobox(cbDelAssociate). I am loading the combo box with a list of names from a table on a worksheet("2015"). With this code:
Code:
For x = 3 To ActiveSheet.Cells(1, 1).SpecialCells(xlLastCell).Row
If ActiveSheet.Cells(x, 1) <> "" Then
DelForm.cbDelAssociate.AddItem ActiveSheet.Cells(x, 1)
End If
Next
The table starts on row 3.
This loads the names just fine but it takes a long time.
I have tried tweaking it but I can't seem to speed it up at all. Is this the wrong approach for what I am doing?
I use this code when the "Delete" button on the userform is clicked:
Code:
Last = ActiveSheet.Cells(Rows.Count, "A").End(xlUp).Row
For i = last To 1 Step -1
If (Cells(i, "A").Value) = DelForm.cbDelAssociate.Value Then
Cells(i, "A").EntireRow.Delete
End If
Next i
cbDelAssociate.Value = "Click Arrow To Select-->"
Then I call the code to load the combobox again (it takes forever again) but the name that was deleted still appears even though it has been removed from the Table.
So I am asking can one of you Gurus help me speed up the loading of the ComboBox. And remove the deleted name from the ComboBox after its removed from the table.
Thank you in advance. You have already helped me more than you know.
D-Dog<o

