I
Ian Baker
I have a client that is experiencing a strange problem using Access 2k & Win
2k on a networked backend/frontend. The scenario is:
1. There is a form which contains fields, a listbox and 2 buttons and is
bound to [tblHelpDesk].
2. The listbox souce is bound to a query based on the same table
[tblHelpDesk] but with set criteria.
3. When a user clicks btnOpenCalls the listbox source changes to
qryOpenCalls to display in the listbox all help desk calls that are open and
when the user clicks btnClosedCalls the listbox source changes to
qryClosedCalls to display all help desk calls in the listbox that are
closed.
4. The user can then click one of the records in the list box and the form
will display the selected record's details using bookmark in the following
code of the On_Click event:
Private Sub CallList_Click()
On Error GoTo HandleErr
Dim rst As Recordset
Set rst = Me.RecordsetClone
rst.FindFirst "CallID = " & Me!CallList
Me.Bookmark = rst.Bookmark
rst.Close
Set rst = Nothing
ExitHere:
Exit Sub
HandleErr:
If Err = 94 Then
CallList = Null
ElseIf Err = 2105 Then
Exit Sub
Else
StandardError Err, Err.Description, "Help Desk - CallList_Click"
End If
Exit Sub
End Sub
The problem is this works fine most of the time with the user clicking any
one of the records in the listbox which may contain 50 or so records and the
form will display the selected record's details. But every now and then the
last couple of records in the listbox (different number each time) when
clicked will always display on the form the very first record that is in the
table and not the one selected. To explain in another way the user can
select say for example any one of the top records in the listbox and the
form displays the corresponding record but when they select any one of the
last few records in the listbox the form displays record 1 of the table.
This doesn't happen everytime.
This is really frustrating me as I have spent a huge amount of time trying
to resolve it but now I am totally lost. Please, if you can offer any advise
then I am greatly indebted.
--
Regards
Ian Baker
Jackaroo Developments Pty Ltd
(Download Jackaroo IT - IT Mgmt and Help Desk application at
http://jackaroo.net.au)
2k on a networked backend/frontend. The scenario is:
1. There is a form which contains fields, a listbox and 2 buttons and is
bound to [tblHelpDesk].
2. The listbox souce is bound to a query based on the same table
[tblHelpDesk] but with set criteria.
3. When a user clicks btnOpenCalls the listbox source changes to
qryOpenCalls to display in the listbox all help desk calls that are open and
when the user clicks btnClosedCalls the listbox source changes to
qryClosedCalls to display all help desk calls in the listbox that are
closed.
4. The user can then click one of the records in the list box and the form
will display the selected record's details using bookmark in the following
code of the On_Click event:
Private Sub CallList_Click()
On Error GoTo HandleErr
Dim rst As Recordset
Set rst = Me.RecordsetClone
rst.FindFirst "CallID = " & Me!CallList
Me.Bookmark = rst.Bookmark
rst.Close
Set rst = Nothing
ExitHere:
Exit Sub
HandleErr:
If Err = 94 Then
CallList = Null
ElseIf Err = 2105 Then
Exit Sub
Else
StandardError Err, Err.Description, "Help Desk - CallList_Click"
End If
Exit Sub
End Sub
The problem is this works fine most of the time with the user clicking any
one of the records in the listbox which may contain 50 or so records and the
form will display the selected record's details. But every now and then the
last couple of records in the listbox (different number each time) when
clicked will always display on the form the very first record that is in the
table and not the one selected. To explain in another way the user can
select say for example any one of the top records in the listbox and the
form displays the corresponding record but when they select any one of the
last few records in the listbox the form displays record 1 of the table.
This doesn't happen everytime.
This is really frustrating me as I have spent a huge amount of time trying
to resolve it but now I am totally lost. Please, if you can offer any advise
then I am greatly indebted.
--
Regards
Ian Baker
Jackaroo Developments Pty Ltd
(Download Jackaroo IT - IT Mgmt and Help Desk application at
http://jackaroo.net.au)