SOLVED

Spaltenvergleich größer, kleiner

Copper Contributor

Hi, ich suche schon verzweifelt im Netz, kann mein Problem aber bisher nicht lösen!

Ich habe 2 Spalten (A,B) und möchte jeweils die B-Werte markieren, wenn sie größer oder kleiner den A-Werten sind (rot bzw. grün). Beispiel: B5 ist größer A5 -> B5 rot, B9 ist kleiner A9 -> B9 grün. Bedingte Formatierung scheint mir der richtige Weg. Hier kann ich die Regeln aber bisher leider nur Zelle für Zelle eingeben. Gibt es auch eine Möglichkeit, dies für markierte Bereiche zu tun? Es sind schließlich hunderte Zellen und wenn ich da jeweils pro Zelle zwei Regeln angeben muss, bin ich nächste Woche noch nicht fertig.

Kann mir jemand helfen?

3 Replies
best response confirmed by FuxLoyd (Copper Contributor)
Solution

@FuxLoyd 

You can do this with just two rules for the entire range.

Let's say the data start in row 2.

Select the range from B2 to the last used row.

I will assume that B2 is the active cell within the selection.

  • On the Home tab of the ribbon, select Conditional Formatting > New Rule...
  • Select 'Format only cells that contain'.
  • Leave the first dropdown set to 'Cell Value'.
  • Select 'greater than' from the second dropdown.
  • Enter the formula =A2 in the box next to it. Remember, 2 is the row of the active cell
  • Click Format...
  • Activate the Fill tab.
  • Select red.
  • Click OK, then click OK again.

Repeat the above steps, but with 'less than' instead of 'greater than' and with green instead of red.

@Hans Vogelaar Top! Es funktioniert. Ich danke dir!

@Hans Vogelaar Thanks for the description, it worked very well and saved my Sunday :)
1 best response

Accepted Solutions
best response confirmed by FuxLoyd (Copper Contributor)
Solution

@FuxLoyd 

You can do this with just two rules for the entire range.

Let's say the data start in row 2.

Select the range from B2 to the last used row.

I will assume that B2 is the active cell within the selection.

  • On the Home tab of the ribbon, select Conditional Formatting > New Rule...
  • Select 'Format only cells that contain'.
  • Leave the first dropdown set to 'Cell Value'.
  • Select 'greater than' from the second dropdown.
  • Enter the formula =A2 in the box next to it. Remember, 2 is the row of the active cell
  • Click Format...
  • Activate the Fill tab.
  • Select red.
  • Click OK, then click OK again.

Repeat the above steps, but with 'less than' instead of 'greater than' and with green instead of red.

View solution in original post