[AccessD] You canceled the previous operation (but I didn't)

Jim Hewson JHewson at karta.com
Mon Feb 26 11:20:25 CST 2007


Try removing the quotes around your cboPartslist.
If it's text it might work as is but if the Parts list is numeric it could give you that error.

Jim 
jhewson at karta.com
 

-----Original Message-----
From: accessd-bounces at databaseadvisors.com [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Rocky Smolin at Beach Access Software
Sent: Monday, February 26, 2007 11:18 AM
To: 'Access Developers discussion and problem solving'
Subject: Re: [AccessD] You canceled the previous operation (but I didn't)

Gustav:

Thanks for your reply.  I tried substituting your code but got the same
result.  This is a bound form and I'm trying to go to the record selected in
the combo box.  As I noted, if I debug and then press F5 it carries on
successfully.  Is perhaps that a clue?

Rocky


-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Gustav Brock
Sent: Monday, February 26, 2007 8:54 AM
To: accessd at databaseadvisors.com
Subject: Re: [AccessD] You canceled the previous operation (but I didn't)

Hi Rocky

Try with:

    If Me.RecordsetClone.NoMatch = True Then
        MsgboxUni Me.hWnd, TranslateMsgbox("PartNumberNotFound"), ,
vbExclamation
        Me.RecordsetClone.MoveFirst
    End If
    Me.Bookmark = Me.RecordsetClone.Bookmark
    'Me.cmdExitDemandSide.SetFocus
    'cboPartsList.Visible = False

Also, you should assign RecordsetClone to a Recordset and then manipulate
that.

/gustav


>>> rockysmolin at bchacc.com 26-02-2007 17:39:07 >>>
Dear List:
 
Can anyone see why I should get an error "2001 - you cancelled the previous
operation" on the statement Me.Bookmark = Me.RecordsetClone.Bookmark in the
following?

    Me.RecordsetClone.FindFirst "[PartNumber] = '" & Me.cboPartsList.Value &
"'"
    MsgBox Me.RecordsetClone.NoMatch
    If Me.RecordsetClone.NoMatch = True Then
        MsgboxUni Me.hWnd, TranslateMsgbox("PartNumberNotFound"), ,
vbExclamation
        DoCmd.GoToRecord , , acFirst
    Else
        Me.Bookmark = Me.RecordsetClone.Bookmark
        'Me.cmdExitDemandSide.SetFocus
        'cboPartsList.Visible = False
    End If

Interestingly, if I hit debug to the error message (and it opens the code
page with that statement highlighted) and I pressF5, it carries on just
fine.
 
MTIA,
 
Rocky

--
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com

--
No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.5.446 / Virus Database: 268.18.4/702 - Release Date: 2/25/2007
3:16 PM
 

-- 
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com



More information about the AccessD mailing list