execution of this application has stopped due to a run-time error

Discussion in 'Access VBA Modules' started by Rajeev, Apr 8, 2009.

  1. Rajeev

    Rajeev Guest

    Hi everybody,
    I developed an application with access and when I tried to deploy the
    application with the access runtime it gives me the following error:

    "Execution of this application has stopped due to a run-time error"
    "The application can't continue an it will shut down."
    It works fine in full version of access..
    The following is the code:
    The function Activity_Enter() calls the StartRecordAtBeginning and
    it(StartRecordAtBeginning) does executes fine but after that I get an error
    message

    "Execution of this application has stopped due to a run-time error"
    "The application can't continue an it will shut down."

    please help me...I'm working on this from last the 3 weeks but i could not
    fix the problem
    Note: its working fine in full version of access.

    Private Sub Activity_Enter() 'this checks TargetID info
    If IsNull(TargetID) Then
    Call StartRecordAtBeginning
    End
    End If
    End Sub
    -----------------------------------------------------------------------------------------------------------------------

    Sub StartRecordAtBeginning()
    If MsgBox("You have not yet entered the target ID#. " & _
    "You must start data entry at the beginning. " & _
    "Click 'Retry' to go back and enter the target " & _
    "ID#, or click 'Cancel' to erase this record without " & _
    "saving it.", vbRetryCancel, "Enter Target ID#") = vbCancel Then
    Call UndoRecordButton_Click
    End
    Else
    Screen.ActiveControl = ""
    TargetID.SetFocus
    End If
    End Sub
     
    Rajeev, Apr 8, 2009
    #1
    1. Advertisements

  2. Rajeev

    Alex Dybenko Guest

    Hi,
    you need to insert error handlers in each proc - then you get a meanful
    message and can find an error. search for mztools - great adding to insert
    error handlers

    --
    Best regards,
    ___________
    Alex Dybenko (MVP)
    http://accessblog.net
    http://www.PointLtd.com


    "Rajeev" <> wrote in message
    news:...
    > Hi everybody,
    > I developed an application with access and when I tried to deploy the
    > application with the access runtime it gives me the following error:
    >
    > "Execution of this application has stopped due to a run-time error"
    > "The application can't continue an it will shut down."
    > It works fine in full version of access..
    > The following is the code:
    > The function Activity_Enter() calls the StartRecordAtBeginning and
    > it(StartRecordAtBeginning) does executes fine but after that I get an
    > error
    > message
    >
    > "Execution of this application has stopped due to a run-time error"
    > "The application can't continue an it will shut down."
    >
    > please help me...I'm working on this from last the 3 weeks but i could not
    > fix the problem
    > Note: its working fine in full version of access.
    >
    > Private Sub Activity_Enter() 'this checks TargetID info
    > If IsNull(TargetID) Then
    > Call StartRecordAtBeginning
    > End
    > End If
    > End Sub
    > -----------------------------------------------------------------------------------------------------------------------
    >
    > Sub StartRecordAtBeginning()
    > If MsgBox("You have not yet entered the target ID#. " & _
    > "You must start data entry at the beginning. " & _
    > "Click 'Retry' to go back and enter the target " & _
    > "ID#, or click 'Cancel' to erase this record without " & _
    > "saving it.", vbRetryCancel, "Enter Target ID#") = vbCancel Then
    > Call UndoRecordButton_Click
    > End
    > Else
    > Screen.ActiveControl = ""
    > TargetID.SetFocus
    > End If
    > End Sub
    >
    >
    >
    >
    >
     
    Alex Dybenko, Apr 9, 2009
    #2
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Sunny Okorie
    Replies:
    1
    Views:
    104
    Marshall Barton
    Jan 15, 2004
  2. Eddie's Bakery and Cafe'

    Run Time Error - "Database has been placed in ... lock state ..."

    Eddie's Bakery and Cafe', Mar 6, 2005, in forum: Access VBA Modules
    Replies:
    0
    Views:
    61
    Eddie's Bakery and Cafe'
    Mar 6, 2005
  3. Run time error 2001

    Run-time error 2001 - in Access 2003 for an application that work.

    Run time error 2001, May 23, 2005, in forum: Access VBA Modules
    Replies:
    1
    Views:
    77
    Allen Browne
    May 23, 2005
  4. Kiraly

    Execution has stopped due to a run-time error

    Kiraly, Jun 2, 2005, in forum: Access VBA Modules
    Replies:
    0
    Views:
    169
    Kiraly
    Jun 2, 2005
  5. Jessica
    Replies:
    11
    Views:
    203
    Marshall Barton
    Jul 7, 2005
  6. Marcus Bulhosa / Analista CEF

    Error Run-time '2501' in method execution: DoCmd.save acReport, "N

    Marcus Bulhosa / Analista CEF, Jul 21, 2006, in forum: Access VBA Modules
    Replies:
    0
    Views:
    125
    Marcus Bulhosa / Analista CEF
    Jul 21, 2006
  7. BlueWolverine

    Trying to run update query in VBA, new error Run time 7874

    BlueWolverine, Apr 9, 2008, in forum: Access VBA Modules
    Replies:
    2
    Views:
    214
    BlueWolverine
    Apr 10, 2008
  8. BlueWolverine

    RUN TIME Error on Code that has ALWAYS worked before

    BlueWolverine, Aug 18, 2008, in forum: Access VBA Modules
    Replies:
    2
    Views:
    105
    BlueWolverine
    Aug 18, 2008
Loading...