Today when I when I run macros that worked fine yesterday(and several months before) they throw this error when they hit a sort operation:
Here is a sample of the code that is errors. The orange code is highlighted yellow in the VBA editor when I debug:
vEnd = Range("B65536").End(xlUp).Row
ActiveWorkbook.Worksheets("Backlog").Sort.SortFields.Clear
ActiveWorkbook.Worksheets("Backlog").Sort.SortFields.Add Key:=Range( _
"C4:C" & vEnd), SortOn:=xlSortOnValues, Order:=xlAscending, DataOption:= _
xlSortTextAsNumbers
Any previously fine macro that has a sort operation is throwing this error. Also if I record a new macro and sort a file then try to rerun that macro I will get the same error. I tried doing a repair on my Office and still get the error. I am currently stuck and not sure what to try to fix this.
This is on a Windows 10 PC running Office 365.
Here is a sample of the code that is errors. The orange code is highlighted yellow in the VBA editor when I debug:
vEnd = Range("B65536").End(xlUp).Row
ActiveWorkbook.Worksheets("Backlog").Sort.SortFields.Clear
ActiveWorkbook.Worksheets("Backlog").Sort.SortFields.Add Key:=Range( _
"C4:C" & vEnd), SortOn:=xlSortOnValues, Order:=xlAscending, DataOption:= _
xlSortTextAsNumbers
Any previously fine macro that has a sort operation is throwing this error. Also if I record a new macro and sort a file then try to rerun that macro I will get the same error. I tried doing a repair on my Office and still get the error. I am currently stuck and not sure what to try to fix this.
This is on a Windows 10 PC running Office 365.