Постоянно получаю сообщение об ошибке «Время выполнения 5: недопустимый вызов процедуры или аргумент»
Sub CopyInputFormtoDatabase()
Dim InputForm As Worksheet
Dim Ticketholderdetails As Worksheet
Set InputForm = Sheets("InputForm")
Set Ticketholderdetails = Sheets("Ticketholderdetails")
Dim answer123 As Integer
Dim nextRow As Integer
answer123 = "1"
nextRow = Ticketholderdetails.Range("A" & Ticketholderdetails.Rows.Count).End(xlUp).Offset(1).Row
If InputForm.Cells("AA7").Value = answer123 Then
nextRow = Ticketholderdetails.Range("A" & Ticketholderdetails.Rows.Count).End(xlUp).Offset(1).Row
Ticketholderdetails.Cells(nextRow, 1).Value = InputForm.Range("L11").Value
Ticketholderdetails.Cells(nextRow, 2).Value = InputForm.Range("S5").Value
Ticketholderdetails.Cells(nextRow, 3).Value = InputForm.Range("L7").Value
Ticketholderdetails.Cells(nextRow, 4).Value = InputForm.Range("S9").Value
Ticketholderdetails.Cells(nextRow, 5).Value = InputForm.Range("S7").Value
Ticketholderdetails.Cells(nextRow, 6).Value = InputForm.Range("L9").Value
Ticketholderdetails.Cells(nextRow, 7).Value = InputForm.Range("S11").Value
Ticketholderdetails.Cells(nextRow, 8).Value = InputForm.Range("H5").Value
Ticketholderdetails.Cells(nextRow, 9).Value = InputForm.Range("H7").Value
Ticketholderdetails.Cells(nextRow, 10).Value = InputForm.Range("H21").Value
Ticketholderdetails.Cells(nextRow, 11).Value = InputForm.Range("H23").Value
Ticketholderdetails.Cells(nextRow, 12).Value = InputForm.Range("H17").Value
Ticketholderdetails.Cells(nextRow, 13).Value = InputForm.Range("H15").Value
Ticketholderdetails.Cells(nextRow, 14).Value = InputForm.Range("H9").Value
Ticketholderdetails.Cells(nextRow, 15).Value = InputForm.Range("H11").Value
Ticketholderdetails.Cells(nextRow, 16).Value = InputForm.Range("H13").Value
Worksheets("Stadium").Range("A1:A50").Value = Worksheets("Ticketholderdetails").Range("A3:A50").Value
Worksheets("Stadium").Range("B1:B50").Value = Worksheets("Ticketholderdetails").Range("F3:F50").Value
Dim SummaryofInformation As Worksheet
Set SummaryofInformation = Sheets("SummaryofInformation")
Dim Stadium As Worksheet
Set Stadium = Sheets("Stadium")
SummaryofInformation.Range("D4:D8").Value = Stadium.Range("E3:E7").Value
Else
MsgBox("Please fill out all boxes of this form before submitting!")
End If
End Sub