يعطى رساله خطا على End sub
Private Sub CommandButton1_Click()
On Error Resume Next
' to prepare requlred data for remaining columns of our sheet
trow = Sheet3.Cells(Rows.Count, 1).End(xlUp).row
For X = 4 To trow
Sheet2.Cells(trow, 1) = TextBox1.Value
Sheet2.Cells(trow, 3) = TextBox3.Value
Sheet2.Cells(trow, 4) = TextBox4.Value
Sheet2.Cells(trow, 5) = TextBox5.Value
Sheet2.Cells(trow, 6) = ComboBox1.Value
Sheet2.Cells(trow, 😎 = TextBox7.Value
Sheet2.Cells(trow, 7) = TextBox6.Value
Sheet2.Cells(trow, 9) = lblfloor.Caption
Sheet2.Cells(trow, 10) = lblroomtype.Caption
Sheet2.Cells(trow, 11) = Label17.Caption
Sheet2.Cells(trow, 12) = Label18.Caption
Sheet2.Cells(trow, 15) = Label19.Caption
' for outo and unique trasaction no
Sheet2.Cells(trow, 19) = Sheet2.Cells(trow = 1, 19) + 1
Unload UserForm4
UserForm4.show
End Sub
Form..xlsm