I am working on an app to speed up & automate processing of Credit Cards statements. After data is input from a CSV file, it is presented to the user. The user is allowed access to 2 columns, 'Account Code' & 'VAT Rate'. Entry is restricted by Data Validation, the user selecting from lists.
Workbook_Change is used to amend data in other columns depending on the selection.
I did work very well, but having corrected other problems & my errors, Workbook_Change no longer works.
Application.EnableEvents is set true.
Help.
Workbook_Change is used to amend data in other columns depending on the selection.
I did work very well, but having corrected other problems & my errors, Workbook_Change no longer works.
Application.EnableEvents is set true.
Help.
Code:
Private Sub Worksheet_Change(ByVal Target As Range)
' Checks whether Account is changed or VAT is set
Dim Msg_Ans As Integer
Dim Msg_Txt As String
Dim VAT1 As Integer
Dim VAT2 As Integer
On Error Resume Next
Target.Range = Range("H:I")
VAT1 = Worksheets("Master").Range("VAT_R1").Value
VAT2 = Worksheets("Master").Range("VAT_R2").Value
If Target.Column = 8 Then
...
...
Range("Q" & ActiveCell.Row).Value = Left(Range("H" & ActiveCell.Row).Value, 3)
End If
If Target.Column = 9 Then
Application.EnableEvents = False
....
....
End If
Application.EnableEvents = True
End Sub