1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45
| Private Sub UserForm_Initialize()
ComboBox1.Clear
ComboBox1.AddItem "TCH Cong" 'ListIndex = 0
ComboBox1.AddItem "TCH Drop" 'ListIndex = 1
ComboBox1.AddItem "SDCCH Cong" 'ListIndex = 2
ComboBox1.AddItem "SDCCH Drop" 'ListIndex = 3
ComboBox1.AddItem "Outgoing HO" 'ListIndex = 4
ComboBox1.AddItem "Incoming HO" 'ListIndex = 5
'combobox1.
'ComboBox1.ListIndex = 0
End Sub
Private Sub interim()
Dim indx, indx1 As Integer
Dim cellname, cellname1 As String
Select Case ComboBox1.Value
'=====================================================================================
Case 0 'TCH Cong
For indx = 2 To 33
cellname = Worksheets("Neighbor_KPI").Range("C" & indx).Value
If cellname = "" Then
GoTo line2
End If
For indx1 = 2 To 949
cellname1 = Worksheets("TCH_CONG").Range("E" & indx1).Value
If cellname = cellname1 Then
Sheets("TCH_CONG").Range("F" & indx1 & ":P" & indx1).Copy
Sheets("Neighbor_KPI").Select
Range("D" & indx).Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
GoTo line
End If
Next indx1
line:
Next indx |
Partager