Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 55
Default Loop for text check in three colums and set a text code based on thisin another column

Simple loop required for handling a enormous amount of data :)
If somebody got a free moment,
thx

For a long list with data in column A till Z I want to set a text in column Z based on a part of text in three other columns. The macro should find the text within text in a cell.

In honkiedonkie explanation it is like;

-----------

Loop in column A for all rows from second to last

If (li, co+13) contains text "AAA"
and (li, co+21) contains text "BBB"
and (li, co+22) contains text "CCC"
then set (li,co+25) the text "A"

Else
If (li, co+13) contains text "DDD"
and (li, co+13) does not contains text "EEE"
and (li, co+22) contains text "FFF"
then set (li,co+25) the text "B"

end if

If (li, co+25) is empty
then set (li, co+25) the text "C"
else
end if

next li

-------------

regards, Johan



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 55
Default Loop for text check in three colums and set a text code based onthis in another column

Thanks!.

The thing thats goes wrong now is that the text in the mentioned columns isn't only the letters I wrote. Those letters are a part of the text within that specific cell.
So the text in li,co+13 could be "Blabla AAA blabla"
The text in li,co+22 could be "BBB Bla bla"
The text in li,co+23 could be "Bla CCC"

The macro has to check if the mentioned text is a part of the whole text in the cell. If in all three columns that specific text is found then...... it results in a code.

regards (and thanks!), Johan
  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 55
Default Loop for text check in three colums and set a text code based onthis in another column

Hello Claus,

Sorry delay reaction. Long working day :)
Tried and a bit changed to fulfill my wishes.
It works fantastic. Also the way you created it for simple understanding.
Many many many thanks !!!

regards, Johan
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 subtract one text column based on their text column MS xls. Salahuddin Excel Discussion (Misc queries) 4 October 27th 08 05:57 AM
Loop through column(s) to check values, perform action based on check ward376 Excel Programming 4 November 6th 07 04:21 PM
Counting a mixed text/number column based on text in another colum Sierra Vista Steve Excel Discussion (Misc queries) 3 December 17th 06 06:30 PM
Putting text in a column based on variable text from another colum Jacky D. Excel Discussion (Misc queries) 1 December 16th 04 07:09 PM
Deleting Rows based on text in cell & formatting cell based on text in column beside it Steve Excel Programming 4 February 26th 04 04:31 PM


All times are GMT +1. The time now is 08:55 PM.

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"