我有一种视图类型“连续表单”的形式,它基于查询返回记录,我希望这些记录有一个数字标签,如 1、2、3 .. 按列出的顺序:
有没有办法在那里自动生成标签或文本框?
任何帮助表示赞赏!谢谢
编辑:继承人查询代码:
Dim qd As DAO.QueryDef
Set qd = CurrentDb.CreateQueryDef("pairsOrdered", "select * from allPairs order by Count desc")
Dim rs As DAO.Recordset
Set rs = CurrentDb.OpenRecordset("pairsOrdered")
If Not rs.EOF Then
Me.Label22.Visible = 0
End If
If Me.OpenArgs = "25" Then
RecordSource = "select top 25 * from pairsOrdered"
End If
If Me.OpenArgs = "50" Then
RecordSource = "select top 50 * from pairsOrdered"
End If
If Me.OpenArgs = "all" Then
RecordSource = "select * from pairsOrdered"
End If