Hi,

Have you thought about a pivot table before going coding a macro?
cells(i,j) notation is about 2 dimensional array. If you want to work any 
values in there, you then need 2 loops. Now, you must know before hand 
which direction you need to take, are you going by rows or by columns? This 
is what confuses me in your query.

going by rows:

i = 3
j = 1
for i = 2 to 31
if cell(i,j) ... 
   then ... 'enter loop j
   for j = 2 to 11
       if cell(i,j)

   next j
end if
next i

going by columns:
i = 2
j = 3
for i = 4 to 11
if cell(i,j) ...
   then
   for j = 3 to 31
      cell(i,j) ...
   next j
next i

If cell(i,j) makes sense, I think you want to loop by rows.

As for me, the way you explain is a little confusing. You should either 
choose a full pseudo code or algorithm or explain this with more words 
because it's difficult to see where i and j are supposed to be. Maybe 
someone else can see this better than me...

Pascal Baro

-- 
-- 
FORUM RULES (986+ members already BANNED for violation)

1) Use concise, accurate thread titles. Poor thread titles, like Please Help, 
Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get 
quick attention or may not be answered.

2) Don't post a question in the thread of another member.

3) Don't post questions regarding breaking or bypassing any security measure.

4) Acknowledge the responses you receive, good or bad.

5)  Cross-promotion of, or links to, forums competitive to this forum in 
signatures are prohibited. 

NOTE  : Don't ever post personal or confidential data in a workbook. Forum 
owners and members are not responsible for any loss.

------------------------------------------------------------------------------------------------------
To post to this group, send email to excel-macros@googlegroups.com

To unsubscribe, send a blank email to excel-macros+unsubscr...@googlegroups.com


Reply via email to