J
Jennifer
Hi there,
I am using the following code when the user hits the enter button on a form.
As you can see values from the various txt boxes, cbo boxes etc. are put into
the 1st blank row at the bottom of the database. What i need now is to know
how to copy the formula in column 7 from the row above, down to be even with
all the data that was just entered. Hope this is clear.
Private Sub cmdAdd_Click()
ActiveWorkbook.Sheets("Sheet3").Activate
'stops flickering
Application.ScreenUpdating = False
Set ws = Worksheets("Database")
iRow = ws.Cells(Rows.Count, 2).End(xlUp).Row + 1
ws.Cells(iRow, 1).Value = "N/A"
ws.Cells(iRow, 6).Value = Me.Calendar1
ws.Cells(iRow, 4).Value = Me.txtPounds.Value
ws.Cells(iRow, 2).Value = Me.cboIngredient.Value
ws.Cells(iRow, 5).Value = "Actual"
ws.Cells(iRow, 7).value = ?????????????
Me.ListBox1.Value = Update
I am using the following code when the user hits the enter button on a form.
As you can see values from the various txt boxes, cbo boxes etc. are put into
the 1st blank row at the bottom of the database. What i need now is to know
how to copy the formula in column 7 from the row above, down to be even with
all the data that was just entered. Hope this is clear.
Private Sub cmdAdd_Click()
ActiveWorkbook.Sheets("Sheet3").Activate
'stops flickering
Application.ScreenUpdating = False
Set ws = Worksheets("Database")
iRow = ws.Cells(Rows.Count, 2).End(xlUp).Row + 1
ws.Cells(iRow, 1).Value = "N/A"
ws.Cells(iRow, 6).Value = Me.Calendar1
ws.Cells(iRow, 4).Value = Me.txtPounds.Value
ws.Cells(iRow, 2).Value = Me.cboIngredient.Value
ws.Cells(iRow, 5).Value = "Actual"
ws.Cells(iRow, 7).value = ?????????????
Me.ListBox1.Value = Update