Closed 9kongpob closed 3 years ago
Private Sub UserForm_Initialize()
ComboBox_Vendor.AddItem "AMT"
ComboBox_Vendor.AddItem "FTPT"
ComboBox_Vendor.AddItem "GTP"
ComboBox_Vendor.AddItem "QPS"
ComboBox_Vendor.AddItem "SASC"
ComboBox_Vendor.AddItem "SMTL"
ComboBox_Vendor.AddItem "SPI"
ComboBox_Vendor.AddItem "SSSC"
End Sub
Private Sub Cancel_Click()
Unload Vendor_Select
End Sub
Private Sub separate_value_Click()
Dim sheet As Worksheet
Unload Vendor_Select
For Each sh In Sheets
If sh.Name = ComboBox_Vendor.Value Then
Application.DisplayAlerts = False
Sheets(ComboBox_Vendor.Value).Delete
Application.DisplayAlerts = True
End If
Next sh
'Sheets.Add After:=Sheets(Sheets.count)
'ActiveSheet.Name = ComboBox_Vendor.Value
Sheets.Add(After:=Sheets(Sheets.count)).Name = ComboBox_Vendor.Value
Call Separate_Mat.Separate_Mat(ComboBox_Vendor.Value)
End Sub
Sub Separate_Mat(cb_value)
'-------------------------------------------------- 'separate value mat 'adjust column / change fill color
End Sub