|
已经解决,虽然繁琐了点
Dim s As Integer, r As Integer
For s = 1 To Cells(1, 255).End(xlToLeft).Column
For r = 2 To Cells(65536, 1).End(xlUp).Row
cl = Cells(r, s).DisplayFormat.Interior.Color
sl = Cells(r, s).DisplayFormat.Font.Color
cx = Cells(r, s).DisplayFormat.Font.Bold
xt = Cells(r, s).DisplayFormat.Font.Italic
mz = Cells(r, s).DisplayFormat.Font.Name
zh = Cells(r, s).DisplayFormat.Font.Size
Cells(r, s).Interior.Color = cl
Cells(r, s).Font.Color = sl
Cells(r, s).Font.Bold = cx
Cells(r, s).Font.Italic = xt
Cells(r, s).Font.Name = mz
Cells(r, s).Font.Size = zh
Cells(r, s).FormatConditions.Delete
Cells(r, s).Borders.LineStyle = True
Next r
Next s
|
|