I would like to extract formula errors via the excel’s “formula check” function for every sheet and run it for a long list of excel files. The results should be populated into a new excel file called “Summary”.
However, I am not sure what went wrong in that section of my workflow and would like to seek for help to solve it. The anchor base is not working as well.
Hope to hear some helpful guidance. Attached is the screenshot and my workflow.
I would like to extract the details of error in cell for every sheets in a list of excel files.
Some excel files may or may not have formula errors, if they have, the nature and no. of errors are different.
Could you advice what is the VBA code that I can apply?
Thanks for sharing. Based on your example, it detects error within a specified range.
For the excel files that I have, the formula errors can appear at any cells and each files have different length depending on the documentations.
I tried to tweak and tailor the vba codes that you shared to cope with the abovementioned scenario (formula errors can appear in any parts within a worksheet).
May I get your advice if I did it correctly?
Sub PopulateErrors()
Dim wks As Worksheet
For Each wks In ActiveWorkbook.Worksheets
With wks
Dim myCell as Range
For Each myCell In ws.Range("")
myCell.Formula = "=#DIV/0!"
Next myCell
End With
Next