การ insert รูปจาก userfrom ไปใส่ใน cell ต้องเขียน vba อย่างไรครับ
Posted: Tue Oct 22, 2019 3:12 pm
Code: Select all
Private Sub CommandButton1_Click()
emptyRow = WorksheetFunction.CountA(Range("B:B")) + 1
Cells(emptyRow, 2).Value = TextBox1.Value
Cells(emptyRow, 3).Value = TextBox2.Value
Cells(emptyRow, 4).Value = TextBox3.Value
Cells(emptyRow, 5).Value = TextBox4.Value
Cells(emptyRow, 7).Value = TextBox5.Value
Cells(emptyRow, 6).Value = DTPicker1.Value
Cells(emptyRow, 8).Value = Image1.Picture
End Sub