I am very novice at Excel-vba, and learn by taking what others have produced and shared online and customizing it to my needs. I have some code that enters data into a spreadsheet at a specific place, and needs to move to the next row for new data. Here is the code I have:
'Code for saving the data in COFF-171
Dim iRow2 As Long
Dim ws2 As Worksheet
Set ws2 = Worksheets("COFF-171")
'find first empty row in database
iRow2 = ws2.Cells.Find(What:="CFDA#", SearchOrder:=xlRows,_
SearchDirection:=xlPrevious, LookIn:=xlValues).Row + 1
With ws2
.Cells(iRow2, 3).Value = Me.CDFANoTxtBx.Value
.Cells(iRow2, 4).Value = Me.ProgramNameComboBx.Value
.Cells(iRow2, 5).Value = Me.SubrecTxtBx.Value
.Cells(iRow2, 6).Value = Me.SubrecExplTxtBx.Value
.Cells(iRow2, 7).Value = Me.TGATxtBx.Value
.Cells(iRow2, 8).Value = Me.AddtlNotesTxtBx.Value
End With
This gets me to the first cell for input and enters the data for that row. What it does not do that I need it to do is go to the next row in preparation for a new data entry. The language works in another table I have because the Find is a wildcard. But I need this one to go to a specific spot in the spreadsheet to start. I'd appreciate any help provided.