If coloumn C, column D,Coloumn E, are equal to each other then put true in coloumnF and if not then put false by vba

If coloumn C, column D,Coloumn E, are equal to each other  then put true in coloumnF and if not then put false by vba
kindly see the sample file
Sample004.xlsm
Avinash SinghAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

aranaCommented:
Does this have to be specifically using VBA? you could also use conditional formatting or an excel formula.
Subodh Tiwari (Neeraj)Excel & VBA ExpertCommented:
You may try something like this...
Sub CompareColumnsCDE()
Dim lr As Long
With Application
    .Calculation = xlCalculationManual
    .EnableEvents = False
    .ScreenUpdating = True
End With
lr = Columns("C:E").Cells.Find("*", SearchOrder:=xlByRows, SearchDirection:=xlPrevious).Row
If lr > 2 Then
    Range("F3:F" & lr).Formula = "=Countif(C3:E3,C3)=3"
    Range("F3:F" & lr).Value = Range("F3:F" & lr).Value
End If
With Application
    .Calculation = xlCalculationAutomatic
    .EnableEvents = True
    .ScreenUpdating = True
End With
End Sub

Open in new window

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
KoenChange and Transition ManagerCommented:
put formula in F :  =if(and(a2=b2,b2=c2),true,false)
Determine the Perfect Price for Your IT Services

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden with our free interactive tool and use it to determine the right price for your IT services. Download your free eBook now!

Aaron TomoskyDirector of Solutions ConsultingCommented:
+1 for the formula. never do in VBA when you can use a simple formula.
Subodh Tiwari (Neeraj)Excel & VBA ExpertCommented:
@Koen
The formula you suggested can be written as...
=And(a2=b2,b2=c2)

Open in new window

Avinash SinghAuthor Commented:
Thnx again Neeraj Sir
Subodh Tiwari (Neeraj)Excel & VBA ExpertCommented:
You're welcome Avinash!
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
VBA

From novice to tech pro — start learning today.