improve this sub and make it run faster. Sub CalculateFNRatio() Dim ws As Worksheet Set…
- User
improve this sub and make it run faster. Sub CalculateFNRatio()
Dim ws As Worksheet Set ws = ThisWorkbook.Sheets("Gantt") ' Change the sheet name as needed
Dim firstTaskRow As Long firstTaskRow = 15
Dim lastRow As Long lastRow = ws.Cells(ws.Rows.Count, "D").End(xlUp).Row
Dim i As Long
For i = firstTaskRow To lastRow
If ws.Cells(i, "F").value = 0 Then ws.Cells(i, "T").Formula = "=count_FNtask/count_task" End If Next i
End Sub
- Assistant
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.