color after depending on 1st value in a cell

P

pedy

Howdy All,

I have another macro request.

I would like to ‘grey out’ a certain qty of cells depending on the 1st
number in another cell. So 1st of all it would have to check in column
B to see if there is any data and then check for the first number in
that cell (there will be many numbers in the cells but we only need the
1st one (Ex.: B3 = “3 / 8 & 8”).

Then it should start counting from column D the found number of cells
multiplied by 2.

Ex.: if Cell B3 contains “3 / 8 & 8” it will count 3 x 2 = 6 (3 cells x
2 = 6 cells)

Then, if after that count (now at I3), in the next cell over (J3) if
the is data in the cell above (J2) then it should apply an
Interior.ColorIndex of 15 for the next cells until there is no data in
the cells above (if nothing after K2 the grey will be applied to cells
J3 & K3 only).

I hope that I’ve described it ok

Any help is appreciated :)

Pedy
 
P

pedy

anyone...?pedy;852706 said:
Howdy All,

I have another macro request.

I would like to ‘grey out’ a certain qty of cells depending on the 1st
number in another cell. So 1st of all it would have to check in column
B to see if there is any data and then check for the first number in
that cell (there will be many numbers in the cells but we only need the
1st one (Ex.: B3 = “3 / 8 & 8”).

Then it should start counting from column D the found number of cells
multiplied by 2.

Ex.: if Cell B3 contains “3 / 8 & 8” it will count 3 x 2 = 6 (3 cells x
2 = 6 cells)

Then, if after that count (now at I3), in the next cell over (J3) if
the is data in the cell above (J2) then it should apply an
Interior.ColorIndex of 15 for the next cells until there is no data in
the cells above (if nothing after K2 the grey will be applied to cells
J3 & K3 only).

I hope that I’ve described it ok

Any help is appreciated :)

Pedy
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top