Sub trialpha()
With ActiveSheet
For i = 40 To 5 Step -1
If .Cells(i, 2).Value <> "" Then DerL = i: Exit For
Next
.Unprotect "3132"
.Range("A5:N" & DerL).Sort Key1:=Range("B5"), Order1:=xlAscending, Header:=xlNo
.Protect "3132", True, True, True
End With
Cells(5, 2).Select
End Sub