eAlchemist
Technical User
I have some code that opens an Excel file, and among other things removes quotation marks from the file. I set display alerts to false, but when it doesn't find a quote, I still get a message box letting me know. Anyone have any ideas on how to suppress this? Here is a snippet of the code:
Code:
With myExcel
.DisplayAlerts = False
Workbooks.Open Filename:=(myPath & myFileName)
Cells.Select
Selection.Replace What:=Chr(34), Replacement:="", _
LookAt:=xlPart, SearchOrder:=xlByRows, _
MatchCase:=False, SearchFormat:=False, _
ReplaceFormat:=False
ActiveWorkbook.Save
ActiveWorkbook.Close
.DisplayAlerts = True
End With
Thanks,
Chris