• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Put Value in a cell as per Conditional Formatting

vijay.vizzu

Member
Dear All,


I want to try a task in excel, but can't able to acheive, so please help me to resolve it


By conditional formatting, i am highlighting the entire row with Yellow color, now i want to put a vba code which can put 1 in a cell (any cell in a column) in that highlighted row. I am trying to put a code like activecell.interior.color = vbyellow, but it can't detect the color cells. Becoz the cells are highlighted by CF.


So is there any way to detect these cells


Please suggest


Regards

Vijay
 
Dear Debraj Roy


Thank you so much, it worked, but i need one more step like, if that value already put in some where then i need to put it in color cell. I mean to say


A1 = AAA

A2 = AAA

A3 = AAA


by conditional formating,A3 filled with color yellow, and i already put value in A1, my requirement is in A1 value should be delete and put the value in A3


The putting value i am refereing is 1, for the purpose of counting unique values, i am using countif (=IF(COUNTIF(BI$11:$BI31,BI31)=1,1,"")) but it can't applied for highlighted cells
 
Back
Top