简体   繁体   中英

Excel VBA - Color of Range Changed when I paste the value from Different Sheet

I'm having a weird problem. I try to copy and paste values only from different sheet to different sheet. However when i try to paste the values, the color change at the targeted cells. Below are the pictures before and after paste.

Before:

之前

After:

在此处输入图片说明

If i delete the values, it become as the first picture. Below is the code i used to copy the values:

Sub TP1Pas()

Sheets("SUMS").Range("B29:F48").Copy
Sheets("Summary").Range("B6").PasteSpecial xlPasteValues

End Sub

Hope you guys can help me for this.

Looks like there is some background conditional formating active in your excel sheet. Check Home > Conditional formatting > Manage Rules to check if there are any existing rules.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM