Excel formula


I need a formula to populate "tab1" with all data in all rows from "tab2" if that row's cell "total" equals "abc".

Thanks in advance for any tips.
Who is Participating?
FaustulusConnect With a Mentor Commented:
Your new request seems quite different from the first. Is it supposedly the same?
The first request isn't easily understood because one may have a hard time finding "that row's cell "total"". The second request shouldn't be difficult. Place this formula in Sheet3!A2:-

Open in new window

Copy to the right for as many columns as you wish to copy, then copy down for as many rows you have in Sheet4.
Of course, this will give you blank rows which you can filter out.
GlowmanConnect With a Mentor Commented:
I don't think a formula will work for you
you need to use VBA and or an autofilter
here is some pseduo code that would work in VBA

public sub MoveData

  dim dblRow as double
  dim dblTarget as double

  do until thisworkbook.sheets(2).range("A" & dblRow).value = ""
    if thisworkbook.sheets(2).range("C" & dblRow).value = "abc" then
       ' Copy the data
       thisworkbook.sheets(2).rows(dblRow & ":" & dblRow).copy thisworkbook.sheets(1).range("A" & dblTarget)
    end if
    dblRow = dblRow+1

end sub

happy coding
crash1624Author Commented:
Thanks for the answer.  To elaborate, I need to copy all row data on "Sheet3" if cell C of that row equals "$0".  I need this row data to copy to "Sheet4"

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.