Sub 单元格格式刷1() ' Dim i As Integer Dim n As Integer Dim s As String Dim L1, L As Integer n = ActiveSheet.Range("B6000").End(xlUp).Row For i = 2 To n L1 = Len(Range("B" & i)) Range("D" & i) = Range("B" & i) & Range("C" & i) L = Len(Range("D" & i)) Range("D" & i).Select With ActiveCell.Characters(Start:=1, Length:=L1).Font .Name = Range("B" & i).Font.Name .FontStyle = Range("B" & i).Font.FontStyle End With With ActiveCell.Characters(Start:=L1 + 1, Length:=L - L1).Font .Name = Range("C" & i).Font.Name .FontStyle = Range("C" & i).Font.FontStyle End With Next i End Sub