Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
cell backgroundcolor
Hello
How can if run a function after an user changed the backgroundcolor of a cell? The function must run with a macro or after leaving the colored cell. Thanks |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
cell backgroundcolor
you cant.
only changing the formula (e.g. the value) if a cell will trigger an event. changing formatting cannot be caught. a workaround is trapping the selection change event.. but you'll have to store the formats in a cache.. then compare the actuals with the cached values when selection changes. this will be cumbersome and slow if the user makes large selections. -- keepITcool | www.XLsupport.com | keepITcool chello nl | amsterdam Starting vba programmer wrote : Hello How can if run a function after an user changed the backgroundcolor of a cell? The function must run with a macro or after leaving the colored cell. Thanks |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
cell backgroundcolor
You can't do it efficiently, but you could use Volatile on the function
Functions For Cell Colors http://www.cpearson.com/excel/colors.htm --- HTH, David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001] My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm Search Page: http://www.mvps.org/dmcritchie/excel/search.htm "keepITcool" wrote in message .com... you cant. only changing the formula (e.g. the value) if a cell will trigger an event. changing formatting cannot be caught. a workaround is trapping the selection change event.. but you'll have to store the formats in a cache.. then compare the actuals with the cached values when selection changes. this will be cumbersome and slow if the user makes large selections. -- keepITcool | www.XLsupport.com | keepITcool chello nl | amsterdam Starting vba programmer wrote : Hello How can if run a function after an user changed the backgroundcolor of a cell? The function must run with a macro or after leaving the colored cell. Thanks |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
cell backgroundcolor
Hello, My question is an adaption of the first thread - I have used the scrpit below to change the background colour of any cell contacts that have been changed. I would like to adapt it to only change cells when the user changes a formula inside the cells. I do not want to protect the cell contents Private Sub Worksheet_Change(ByVal Target As Range) Target.Interior.ColorIndex = 37 Target.Interior.Pattern = xlSolid End Sub -- st120869 ------------------------------------------------------------------------ st120869's Profile: http://www.excelforum.com/member.php...o&userid=18330 View this thread: http://www.excelforum.com/showthread...hreadid=492658 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Code to copy the formulae of one cell to all the cell in the rangewith the specific cell and columnnumber changing Options | Excel Discussion (Misc queries) | |||
Populate a cell if values in cell 1 and cell 2 match cell 3 and 4 | Excel Worksheet Functions | |||
How to create/run "cell A equals Cell B put Cell C info in Cell D | Excel Discussion (Misc queries) | |||
Change backgroundcolor | Excel Discussion (Misc queries) | |||
Assigning backgroundcolor to button on form | Excel Programming |