Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Here I present you the code to validate the content of a cell (check if it is
null) and change the cell color accordingly if the value in the cell is blank. Please follow following steps 1.Click toolmacro from the menu bar 2.In the macro dialog box, give a name of a macro and click create 3.From the project explorer, double click on sheet1 4.From the drop down list to the left select Worksheet and paste following codes # Private Sub Worksheet_SelectionChange(ByVal Target As Range) If Target.Value = "" Then Target.Interior.Color = vbRed End If End Sub # Hope this works for you Have a nice time€¦. Chris ------ Convert your Excel spreadsheet into an online calculator. http://www.spreadsheetconverter.com -- Message posted via http://www.officekb.com |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
color coding | Excel Discussion (Misc queries) | |||
color coding | Excel Discussion (Misc queries) | |||
Color coding cells | Excel Discussion (Misc queries) | |||
color coding | Excel Worksheet Functions | |||
Color coding | Excel Discussion (Misc queries) |