Every time i search for customer name i get this error:
run-time error '1004' application-defined or object-defined error excel 2013.
here it's the code:
give the above error and highlight this line in yellow:
thank you
run-time error '1004' application-defined or object-defined error excel 2013.
here it's the code:
Code:
If ComboBox1.Value = "" Or ComboBox1.Value = "-" Then
MsgBox "Choose a Filter Field", vbExclamation
ComboBox1.SetFocus
Exit Sub
End If
For a = 1 To 12 ' Clear textboxes(1-12)
Controls("textbox" & a) = ""
Next
With ContactForm
.Clear
.ColumnCount = 12
.ColumnWidths = "92;65;110;65;65;35;40;65;65;115;150;65"
End With
Call Main 'Progress Bar
deg2 = TextBox13.Value
Select Case ComboBox1.Value
Case "Customer"
For sat = 2 To Cells(65536, "A").End(xlUp).Row
Set deg1 = Cells(sat, "A")
If UCase(deg1) Like UCase(deg2) & "*" Then
ContactForm.AddItem
Cells(sonsat, 1) = TextBox1.Text '(Customer) A
Cells(sonsat, 2) = TextBox2.Text '(Contact Name)B
Cells(sonsat, 3) = TextBox3.Text '(Email) C
Cells(sonsat, 4) = TextBox4.Text '(Address)D
Cells(sonsat, 5) = TextBox5.Text '(City)E
Cells(sonsat, 6) = TextBox6.Text '(Province/State)F
Cells(sonsat, 7) = TextBox7.Text '(Zip/Postal Code)G
Cells(sonsat, 8) = TextBox8.Text '(Country)H
Cells(sonsat, 9) = TextBox9.Text '(Phone)I
Cells(sonsat, 10) = TextBox10.Text '(Contact Name, C.C.)J
Cells(sonsat, 11) = TextBox11.Text '(Email C. C.)K
Cells(sonsat, 12) = TextBox12.Text '(Contact Name 2)L
'Cells(sonsat, 16) = TextBox17.Text '(Contact Email 2)M
'Cells(sonsat, 17) = TextBox18.Text '(Manager) N
s = s + 1
End If: Next
give the above error and highlight this line in yellow:
Code:
Cells(sonsat, 1) = TextBox1.Text '(Customer) A
thank you