发布网友 发布时间:2022-05-01 10:48
共1个回答
热心网友 时间:2023-10-09 08:36
Private Sub OptionButton1_Click()追答Private Sub OptionButton1_Click()
Range("A1:C8").Interior.Color = 5287936 '1
With Selection.Interior
.Color = 5287936
End With
End Sub
Private Sub OptionButton2_Click()
Range("A1:C8").Interior.Color = 255 '1‘所选择a1-c8单元格
With Selection.Interior '所选择all单元格
.Color = 255
End With
End Sub
两种方法。录制一个宏,设置快捷键,在宏代码中加一句UserForm1.Show