dannyok90
Board Regular
- Joined
- Aug 30, 2016
- Messages
- 115
Hi all,
See the code below, its working fine apart from if the user selects 'No' in the dialogue box, see the pictures attached. it comes up with some run time error, how do I stop this?
Thanks
[/url]
See the code below, its working fine apart from if the user selects 'No' in the dialogue box, see the pictures attached. it comes up with some run time error, how do I stop this?
Thanks
Code:
Public Sub SaveAsC3()
Dim ThisFile As String, DoF As String
ThisFile = Range("C3").Value
DoF = Range("V2").Value
ActiveWorkbook.Save
ActiveWorkbook.SaveAs Filename:="C:\Users\OKEED3\Documents\Templates\Saved\" & ThisFile & " " & "PSR" & " " & DoF, FileFormat:=xlOpenXMLWorkbookMacroEnabled
ActiveWorkbook.Close
End Sub