Highlight 3 diagonals

Kishan

Well-known Member
Joined
Mar 15, 2011
Messages
1,648
Office Version
  1. 2010
Platform
  1. Windows
Using Excel 2000

Hi,

I need to highlights 3 diagonals weather are they numbers or alphabets

In the example below check first column C to find diagonal in the column D & E

For example C6 is empty go for C7 if C7 is empty go for C8,
Yes find diagonal in C8, D9 & in E10 (in this case as in the row 8 find Diagonal check the complete row C8:P8 and highlight all diagonal) as found one more in the row 8 in cells M8, N10 & in O10 and continue same method to find all possible diagonal

Example data with numbers...


Book1
ABCDEFGHIJKLMNOP
1
2
3
4
5ROW NC1C2C3C4C5C6C7C8C9C10C11C12C13C14
66555
775555
8855555555
9955555555
10105555555
11115555
121255555
131355555555
14145555
151555555555
161655555555
17175555
181855555
1919555555555
2020555555
2121555555555
22225555555
23235555555
242455555555555
252555555
2626555555
272755555
2828555555555
292955555555
303055555
31315555555
32325555
333355555
34345555555
353555555555
363655555555
37375555555555
383855555555
3939555555
404055555
414155555555
4242555555
434355555555
44445555555555
45455555
46465555555
47475555555555
4848555555
494955555
505055555
51515555555555
52525555
5353555555555
54545555555
555555555
565655555555
57575555555
5858555555
59595555
60605555555
61615555
626255555555555
6363555555
6464555555
656555555555
66665555555
67675555555
6868555
696955555
7070555555
717155555
7272555555
7373555555
7474555555
757555555555
7676555555
777755
7878555
7979
8080
Sheet1


Example data with alphabets...


Book1
ABCDEFGHIJKLMNOP
1
2
3
4
5ROW NC1C2C3C4C5C6C7C8C9C10C11C12C13C14
66AAA
77AAAA
88AAAAAAAA
99AAAAAAAA
1010AAAAAAA
1111AAAA
1212AAAAA
1313AAAAAAAA
1414AAAA
1515AAAAAAAA
1616AAAAAAAA
1717AAAA
1818AAAAA
1919AAAAAAAAA
2020AAAAAA
2121AAAAAAAAA
2222AAAAAAA
2323AAAAAAA
2424AAAAAAAAAAA
2525AAAAA
2626AAAAAA
2727AAAAA
2828AAAAAAAAA
2929AAAAAAAA
3030AAAAA
3131AAAAAAA
3232AAAA
3333AAAAA
3434AAAAAAA
3535AAAAAAAA
3636AAAAAAAA
3737AAAAAAAAAA
3838AAAAAAAA
3939AAAAAA
4040AAAAA
4141AAAAAAAA
4242AAAAAA
4343AAAAAAAA
4444AAAAAAAAAA
4545AAAA
4646AAAAAAA
4747AAAAAAAAAA
4848AAAAAA
4949AAAAA
5050AAAAA
5151AAAAAAAAAA
5252AAAA
5353AAAAAAAAA
5454AAAAAAA
5555AAAAA
5656AAAAAAAA
5757AAAAAAA
5858AAAAAA
5959AAAA
6060AAAAAAA
6161AAAA
6262AAAAAAAAAAA
6363AAAAAA
6464AAAAAA
6565AAAAAAAA
6666AAAAAAA
6767AAAAAAA
6868AAA
6969AAAAA
7070AAAAAA
7171AAAAA
7272AAAAAA
7373AAAAAA
7474AAAAAA
7575AAAAAAAA
7676AAAAAA
7777AA
7878AAA
7979
8080
Sheet2


Thank you in advance

Kishan
 
Hi Rick Rothstein, Ok I got it how to execute the line code " Len(Range("G8").Value)" in the VBA editor's Immediate Window pointing mouse on the code line I can see this (Range ("G8").Value = "")
I run the new code from the post# 29 no luck it is resulting as shown in the post#26
It is very hard to diagnose program from afar. Can you send me a copy of your workbook with the raw data before you do anything to it so that I can watch my code run against your actual data in order to be able to debug it live? My email address is...

rick DOT news AT verizon DOT net
 
Upvote 0

Excel Facts

Can you sort left to right?
To sort left-to-right, use the Sort dialog box. Click Options. Choose "Sort left to right"

Forum statistics

Threads
1,223,896
Messages
6,175,265
Members
452,627
Latest member
KitkatToby

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top