Access: Research Page 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17

Visual Basic Code

Writing Code is like eating in a fancy restaurant: so many choices on the menu. So many forks and knives surrounding the plate! Start from the outside and work your way to the middle.

 

Your code starts with Private Sub and stops with End Sub:

 

            Private Sub Movie_DblClick(Cancel As Integer)

   

            End Sub

 

If there’s a problem with the subroutine, there should be a way out. Add the following Error trapping code:

 

            Private Sub Movie_DblClick(Cancel As Integer)

            On Error GoTo Err_Movie_DblClick

 

            Err_Movie_DblClick:

                        MsgBox Err.Description

                        Resume Exit_Movie_DblClick

   

            End Sub