Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Shaun E on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

"You Cancelled the Previous Operation" Error

Status
Not open for further replies.

sgfromny

Technical User
Jan 17, 2003
120
US
Why Would I Get This Error?

Help Appreciated
Thanks
 
Dunno, what were you doing when you got it?
B

----------------------------------------------
Ben O'Hara "Where are all the stupid people from...
...And how'd they get so dumb?"
rockband.gif
NoFX-The Decline
----------------------------------------------
Want to get great answers to your Tek-Tips questions? Have a look at F
 
I made some changes to some code, debugged it, created an MDE. and now the MDE does not function properly, the form that the code was backing does not display and the MDB File where Im debugging that problem is where Im getting the error. (While im in the code and working in the form)
 
what was the code you made changes to?

----------------------------------------------
Ben O'Hara "Where are all the stupid people from...
...And how'd they get so dumb?"
rockband.gif
NoFX-The Decline
----------------------------------------------
Want to get great answers to your Tek-Tips questions? Have a look at F
 
Sounds like the common 2501 error which is triggered when you cancel the opening of a report or other DoCmd action. All you need to do is place an error handler in the event or procedure that is raising it:
Code:
Private Sub MyProcedure()
On Error Goto ErrHandler

  'code that triggers cancel error

ExitHere:
  Exit Sub
ErrHandler:
  If Err <> 2501 Then
    MsgBox "Error occurred: " & Err & "-" & Err.Description
  End If
  Resume ExitHere
End Sub

VBSlammer
redinvader3walking.gif

[sleeping]Unemployed in Houston, Texas
 
John - I think that would be "You cancelled the previous operation"

Rgds, Geoff

"Three things are certain: Death, taxes and lost data. Guess which has occurred"

Please read FAQ222-2244 before you ask a question
 
Ok, but Im getting this error as i just look in the code window., No code is running...??
 
Do you have a timer interval set? Sometimes the debugger acts crazy when you have a timer event firing.

VBSlammer
redinvader3walking.gif

[sleeping]Unemployed in Houston, Texas
 
I have timer events, none of which are in the active form or should be firing.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top