hello
i am a total newb to macros/vb.
my problem is . Weekly I receive a speadsheet in which column H contains
randomly entered words depicting work performed by an individual in different
areas of their work. in column D is the total amount of time taken for that
piece of work.
I wish to search column H for a specific string and then total the
corresponding entry in column d to work out how much time was spent on the
searched for item.
make sense?
can anyone help me with this?
thank you in anticipation.
Hi Adelaide
Try
=SUMIF(Column H,quot;my wordquot;,Column D)
Where Column H is your data range for text
quot;My Wordquot; is the text string
and Column D is your range to be summed.
You can put this formula any where you like or in a macro
HTH
Michael
quot;adelaidequot; wrote:
gt; hello
gt; i am a total newb to macros/vb.
gt; my problem is . Weekly I receive a speadsheet in which column H contains
gt; randomly entered words depicting work performed by an individual in different
gt; areas of their work. in column D is the total amount of time taken for that
gt; piece of work.
gt;
gt; I wish to search column H for a specific string and then total the
gt; corresponding entry in column d to work out how much time was spent on the
gt; searched for item.
gt; make sense?
gt; can anyone help me with this?
gt; thank you in anticipation.
If you want to see 1 total for the item in column H which might have
more than 1 entry - then I would try the following: Enter the following
in Cell I1 or any other blank cell. Replace the quot;XXXXXXquot; what you want
to look for.
This will only work if the cell contains only the quot;Textquot; you want to
find, (i.e Apples, it will not work if the cell is quot;APPLES10quot;)
=SUMIF(H:H,quot;XXXXXXquot;,D).
If you want to quot;Know what cell contains your text, and have it indicate
it in column I then you can use the following formula - enter into cell
I1 and copy down as far as you need to go.
=IF(H1=quot;XXXXXXquot;,D1)
If it somethin else you might need to give more information of how
Column H is setup and how you want to quot;Totalquot; Column D.--
wjohnson
------------------------------------------------------------------------
wjohnson's Profile: www.excelforum.com/member.php...oamp;userid=29640
View this thread: www.excelforum.com/showthread...hreadid=508805
- Feb 22 Thu 2007 20:35
find text in column h and total the corresponding numbers if colum
close
全站熱搜
留言列表
發表留言