none
Visual Basics RRS feed

  • Question

  • Hi I have problem in trying to run a portion of my code on a particular computer. When I run this part of my visual basic code in access 2013 on my computer it works, but it doesn't work on my friend's computer. He gets some error lock or something like that?? Here is the code:

    Private Sub Txt_Date_AfterUpdate()
    On Error GoTo Err_Trap
        Dim frm As Form
        Dim intnewrec As Integer
     
        intnewrec = Me.Form.NewRecord
       
        If intnewrec = True Then
            SendKeys "{f9}", True
            DoCmd.OpenQuery "AppendHourlyLoad", acViewNormal, acReadOnly
            DoCmd.OpenQuery "UpdateHourlyLoad", acViewNormal, acReadOnly
            SendKeys "{f9}", False
        End If


    Exit_Point:
        Exit Sub

    Err_Trap:
        MsgBox Err.Description
        Resume Exit_Point

    End Sub

    Friday, June 23, 2017 5:09 PM

All replies

  • Hi I have problem in trying to run a portion of my code on a particular computer.

    Questions related to Visual Basic for Applications should be asked in the Visual Basic for Applications  (VBA) forum.

    When you ask the question there be sure to include the exact error message that you are seeing.

    Friday, June 23, 2017 10:13 PM