Private Sub Worksheet_SelectionChange(ByVal Target As Range) Cells.Interior.ColorIndex = xlNone '十字光标定位 Rows(Target.Row).Interior.Color = RGB(192, 192, 192) ‘行着色 Columns(Target.Column).Interior.Color = RGB(192, 192, 192) '列着色End Sub吧这个代码放到你的表格里RGB(192, 192, 192)中的数字为0-255 不同数字颜色不同,请自行调整
Copyright © 2025 IZhiDa.com All Rights Reserved.
知答 版权所有 粤ICP备2023042255号