I have the following macro below. Where file does not exist, the data to be cleared in active sheet from A19:AA100
The Macro below to clear the data and combined with above macro (possibly a message box could be incorporated and if file does not exits, then range A19:AA100 on active sheet to be cleared)
Your assistance regarding the above is most appreciated
Code:
Sub DataRefresh()
Application.DisplayAlerts = False
Range("E14").Select
Selection.QueryTable.Refresh BackgroundQuery:=True
Range("G19").Select
Application.DisplayAlerts = True
End Sub
The Macro below to clear the data and combined with above macro (possibly a message box could be incorporated and if file does not exits, then range A19:AA100 on active sheet to be cleared)
Code:
Sub Clear_Data ()
Range(A19:AA100).clearcontents
end sub
Your assistance regarding the above is most appreciated
Last edited: