Dear Sir,
I have added new Userform1 and added combobox1 + label1 and textbox1 + label1. Then added command button1 (name is submit) (when you click this button it will add info to excel sheet). I want to see combobox1 as filter which including name of material and cost. When I click selected material, it should be added this information to the any excel sheet.
I know there is something missing and cannot do it. Could you please help me to create new Userform and including combobox which I can filter and select material name (material names need to be took from any excel sheet) and when I click ok then this need to be saved "account" sheet (each time need insert new row).
I appreciate your help.
Thank you in advance
I have added new Userform1 and added combobox1 + label1 and textbox1 + label1. Then added command button1 (name is submit) (when you click this button it will add info to excel sheet). I want to see combobox1 as filter which including name of material and cost. When I click selected material, it should be added this information to the any excel sheet.
I know there is something missing and cannot do it. Could you please help me to create new Userform and including combobox which I can filter and select material name (material names need to be took from any excel sheet) and when I click ok then this need to be saved "account" sheet (each time need insert new row).
I appreciate your help.
Thank you in advance
Code:
Private Sub CommandButton1_Click()
If ComboBox1 = vbNullString Or TextBox1 = vbNullString Or TextBox2 = vbNullString Then
MsgBox "Please add date"
Else
Sheets("account" + ComboBox1.Value).Rows(6).Insert
Sheets("account" + ComboBox1.Value).Range("C6") = TextBox2
Unload UserForm1
End sub