I am using the function below to copy values in a field until it reaches the following a value that is <> null...it works fine(see vba below), however I need to accomplish a similar task to copy the next record from a different field and then paste it into the null values. Please assist!
EX: I want the null value in "FIELD TWO" to equal 3 from "FIELD ONE" and the second null from "FIELD TWO" to equal 5 etc.
FIELD ONE FIELD TWO
1 7
2
3 8
4
5 10
Function monkeythought()
Dim u As String
Set Mydb = CurrentDb()
Set Myds = Mydb.OpenRecordset("Number")
Myds.MoveFirst
Do While Not Myds.EOF
Myds.Edit
For Each myfld In Myds.Fields
If myfld.Name = "one" Then
If Myds(myfld.Name).Value <> "" Then
u = Myds(myfld.Name).Value
Else
Myds(myfld.Name).Value = u
Myds.Update
End If
End If
Next myfld
Myds.MoveNext
Loop
End Function