Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Excel Macro Query - Search for specific text in cells of a column

Hi all

I'm new to this site and I wondered if anyone could help me with th
following query:

I have a financial spreadsheet with expenditure types in Column
(specified from a drop down list) and a corresponding transaction dat
(Column B) and amount (Column C).

What I would like to do is use a macro to "look" down column A and fo
every occurence of a particular transaction type in the drop down list
add the corresponding monetary values together and put then in a cel
for that particular month. For example, all the "petrol" expenditur
for October is added together and pasted into another table for th
given month.

Can a macro do this easily and what macro functions would I use? I ha
my eye on VLOOKUP, but I'm not sure it can cope with multiple occurence
and so on. I have limited experience with macros, so any example cod
would be great!

Any help would be greatly appreciated.

Many thanks

Nei

--
Message posted from http://www.ExcelForum.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,885
Default Excel Macro Query - Search for specific text in cells of a column

Hi
I would not use a macro for this. you may either consider using a pivot
table or SUMPRODUCT for adding your values. See:
http://www.cpearson.com/excel/pivots.htm
http://peltiertech.com/Excel/Pivots/pivotstart.htm
http://www.contextures.com/xlPivot02.html
http://www.ozgrid.com/Excel/excel-pivot-tables.htm


and
http://www.xldynamic.com/source/xld.SUMPRODUCT.html


--
Regards
Frank Kabel
Frankfurt, Germany


Hi all

I'm new to this site and I wondered if anyone could help me with the
following query:

I have a financial spreadsheet with expenditure types in Column A
(specified from a drop down list) and a corresponding transaction

date
(Column B) and amount (Column C).

What I would like to do is use a macro to "look" down column A and

for
every occurence of a particular transaction type in the drop down
list, add the corresponding monetary values together and put then in
a cell for that particular month. For example, all the "petrol"
expenditure for October is added together and pasted into another
table for the given month.

Can a macro do this easily and what macro functions would I use? I
had my eye on VLOOKUP, but I'm not sure it can cope with multiple
occurences and so on. I have limited experience with macros, so any
example code would be great!

Any help would be greatly appreciated.

Many thanks

Neil


---
Message posted from http://www.ExcelForum.com/


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Excel Macro Query - Search for specific text in cells of a column

Hi Frank, thanks for the prompt reply.

The links look excellent and I will certainly read up on them. I di
have using macros in mind, as I'm a bit more confident with them, s
I'd welcome any further suggestions people may have.

Thanks again

Nei

--
Message posted from http://www.ExcelForum.com

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to search Excel files based on a specific text string in VBA c Bob Excel Discussion (Misc queries) 1 March 6th 09 05:09 AM
search column of text cellto identify those cells with specific w Ross Headifen Excel Worksheet Functions 1 July 8th 06 02:49 PM
Excel XP VBA code to search all macro code in Excel module for specific search string criteria Ed[_18_] Excel Programming 4 May 20th 04 02:08 PM
Excel XP VBA code to search all macro code in Excel module for specific search string criteria Frank Kabel Excel Programming 0 May 19th 04 08:11 PM
Macro to search a column for a specific word and replace with wendy Excel Programming 5 January 19th 04 05:41 PM


All times are GMT +1. The time now is 11:12 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"