I have a Form with a subform. The subform is a continuous form. Upon clicking the subform area, I highlight the selected row and display the details. When a Sort option is selected, I want to keep the current line highlighted. To accomplish this I use the following code: (Access 2002 'adp' SQL Server)
Me.Form.InputParameters = "@XSortOrder nvarchar = '" & XSQLOrder & "'"
Me.Form.Requery
Me.Form.Recordset.Find "[EmpKey] = '" & strSave
The FIND command does not always find a match, in which case it defaults to the 1st row displayed in the subform. I have heard that only a certain amount of records are returned at a time, so the Find command may not return a match.
If I insert a Msgbox command after the Requery, it works, seems like a timing issue. How do I handle this?
Me.Form.InputParameters = "@XSortOrder nvarchar = '" & XSQLOrder & "'"
Me.Form.Requery
Me.Form.Recordset.Find "[EmpKey] = '" & strSave
The FIND command does not always find a match, in which case it defaults to the 1st row displayed in the subform. I have heard that only a certain amount of records are returned at a time, so the Find command may not return a match.
If I insert a Msgbox command after the Requery, it works, seems like a timing issue. How do I handle this?