access db中的单元格为空时如何填充

how to fill down when empty cells in access db

数据库访问table

请帮助我填写以前的字符串PS:我是初学者

您的 Date 字段似乎是数据类型 Text。如果是这样,请将其更改为 DateTime.

然后你可以运行一个循环来更新没有日期值的记录:

Dim Records     As DAO.Recordset

Dim Sql         As String
Dim LastDate    As Date

Sql = "Select * From YourTable Order By [Surevey ID]"
Set Records = CurrentDb.OpenRecordset(Sql)

If Records.RecordCount > 0 Then
    LastDate = Date ' Adjust if needed.
    Records.MoveFirst
    While Not Records.EOF
        If IsNull(Records!Date.Value) Then
            Records.Edit
                Records!Date.Value = LastDate
            Records.Update
        Else
            LastDate = Records!Date.Value
        End If
        Records.MoveNext
    Wend
End If
Records.Close