What is that first line supposed to do?

You could use this instead:

Range("A6:A" & Cells(Rows.Count, "C").End(xlUp).Row).Select
        ActiveWorkbook.Names.Add Name:="assignedreps", RefersToR1C1:= _
                                 "='Accounts by Contract Rep'!R6C1:R" & Cells(Rows.Count, "A").End(xlUp).Row & "C1"