Hi we have a database frontend/backend and am moving the backend to an SQL server.
This seems to have stopped the next and previous button working on the form although the add new button still works. The form is opened to a specified record via and another form using this code
This works nicely, the form opens at the required record, on the opened form are a previous and next button, clicking the previous button gives an error “you can’t go to the specified record” clicking the next button creates a new blank record, this is most likely due to Allow Additions = yes.
I have an idea that when the form is opened the stLinkCriteria from the opening form is creating a recordset of 1 record but I need to have a next&prev buttons on the main form that work.
The old database opened the form with the “Find and Replace” menu item open and then the user searched for their given record but this doesn’t work with the SQL backend for some reason, it just hangs.
Now Im stumped.:banghead:
This seems to have stopped the next and previous button working on the form although the add new button still works. The form is opened to a specified record via and another form using this code
Code:
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "frmForm"
stLinkCriteria = "[ID]=" & "'" & [Text0] & "'"
DoCmd.OpenForm stDocName, , , stLinkCriteria
I have an idea that when the form is opened the stLinkCriteria from the opening form is creating a recordset of 1 record but I need to have a next&prev buttons on the main form that work.
The old database opened the form with the “Find and Replace” menu item open and then the user searched for their given record but this doesn’t work with the SQL backend for some reason, it just hangs.
Now Im stumped.:banghead: