I'm using this code to scan a named range and extract data from rows that contain a "/" in a specific column. The macro works fine but takes roughly 20 seconds to scan about 730 rows. Here's the code:
VBA Code:
Sub RunPlanRequests()
Application.EnableEvents = False
Application.ScreenUpdating = False
Application.DisplayAlerts = False
Sheets("FloorPlanRequests").Visible = True
Sheets("FloorPlanRequests").Select
Dim MR As Excel.Range
Dim rngCell As Excel.Range
Dim rngCount As Long
Dim ws As Worksheet
Set ws = Sheets("Calendar")
Set MR = ws.Range("CalendarFloorsOrderNumberColumn")
rngCount = 1
For Each rngCell In MR
If rngCell.Value Like "*/*" Then
With Sheets("FloorPlanRequests").Range("A" & rngCount)
.Value = rngCell.Value
.Offset(, 1).Resize(, 3).Value = Array(ws.Range("F" & rngCell.Row).Value, ws.Range("AS" & rngCell.Row).Value, ws.Range("B" & rngCell.Row).Value)
End With
rngCount = rngCount + 1
End If
Next rngCell
Application.EnableEvents = True
Application.ScreenUpdating = True
Application.DisplayAlerts = True
End Sub