如何在excel (所有单元格)中使用VBA将所有工作表的填充颜色设置为No fill
。与选择所有工作表相同,选择所有单元格(Control+A)并将fill color
更改为No fill
。
发布于 2016-12-05 19:53:53
未经测试,但应该可以完成这项工作:
Sub No_Fill_Wb()
Dim ws as worksheet
For each ws in Thisworkbook.Worksheets
ws.Cells.Interior.ColorIndex = 0
Next ws
End Sub
发布于 2018-07-20 01:57:18
我在使用Excel 2016的代码中使用了"0“(见下文),它将我的列变成了黑色。
Master.Columns(Col_Start).Interior.Color = 0
然而,使用下面的"xlNone“per对我来说是有效的。
Master.Columns(Col_Start).Interior.Color = xlNone
发布于 2022-02-16 15:46:22
xlNone不适用于BackgroundPatternColor,但wdColorAutomatic适用
currentCell.Shading.BackgroundPatternColor = wdColorAutomatic
https://stackoverflow.com/questions/40973322
复制相似问题