PanzerRanger
New Member
- Joined
- Jan 3, 2018
- Messages
- 20
I know I have error after resume, but it won't trigger. Why won´t Resume exit the error handler
On Error Resume Next
cap = QUL_Import_Form.CAPnr
file = QUL_Import_Form.Anlnr
If Err.Number = 13 Or cap = 0 Then
MsgBox "Felaktig data har angivits! Exporteringen avbryts." & vbNewLine & "Både anläggningsnummer och antal centralapparater måste anges."
Exit Sub
End If
Resume
Workbooks(file & ".xls").Activate 'just passes by even if the workbook is´nt open
Cheers!
On Error Resume Next
cap = QUL_Import_Form.CAPnr
file = QUL_Import_Form.Anlnr
If Err.Number = 13 Or cap = 0 Then
MsgBox "Felaktig data har angivits! Exporteringen avbryts." & vbNewLine & "Både anläggningsnummer och antal centralapparater måste anges."
Exit Sub
End If
Resume
Workbooks(file & ".xls").Activate 'just passes by even if the workbook is´nt open
Cheers!
Last edited: