Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 21
Default Detecting particular BG Color in one cell and duplicate it in anot

Excel 2007....I have two worksheets where I need to detect a particular cell
background color in one of the worksheets and duplicate in another (not the
same formated sheet). I need to do this in a VBA Macro. I hope this is
enough information.....
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5,441
Default Detecting particular BG Color in one cell and duplicate it in anot

Try

Different workbooks:
Workbooks("Workbook Name 2.xls").Worksheets("Sheet Name 2").Range("B2").Interior.ColorIndex = _
Workbooks("Workbook Name 1.xls").Worksheets("Sheet Name 1").Range("A1").Interior.ColorIndex

Different worksheets within the same workbook:
Worksheets("Sheet Name 2").Range("B2").Interior.ColorIndex = _
Worksheets("Sheet Name 1").Range("A1").Interior.ColorIndex

Note that this may not work if either cell has conditional formatting....

HTH,
Bernie
MS Excel MVP


"RidgeView" wrote in message
...
Excel 2007....I have two worksheets where I need to detect a particular cell
background color in one of the worksheets and duplicate in another (not the
same formated sheet). I need to do this in a VBA Macro. I hope this is
enough information.....



  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 21
Default Detecting particular BG Color in one cell and duplicate it in

Thank You very much....your solution worked great!!!!

"Bernie Deitrick" wrote:

Try

Different workbooks:
Workbooks("Workbook Name 2.xls").Worksheets("Sheet Name 2").Range("B2").Interior.ColorIndex = _
Workbooks("Workbook Name 1.xls").Worksheets("Sheet Name 1").Range("A1").Interior.ColorIndex

Different worksheets within the same workbook:
Worksheets("Sheet Name 2").Range("B2").Interior.ColorIndex = _
Worksheets("Sheet Name 1").Range("A1").Interior.ColorIndex

Note that this may not work if either cell has conditional formatting....

HTH,
Bernie
MS Excel MVP


"RidgeView" wrote in message
...
Excel 2007....I have two worksheets where I need to detect a particular cell
background color in one of the worksheets and duplicate in another (not the
same formated sheet). I need to do this in a VBA Macro. I hope this is
enough information.....




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Detecting Duplicate Sums - Worksheet code [email protected] Excel Discussion (Misc queries) 0 September 27th 07 02:20 AM
detecting duplicate input in a cell leo Excel Worksheet Functions 1 January 22nd 07 08:06 AM
detecting duplicate input in a cell leo Excel Worksheet Functions 0 January 22nd 07 07:29 AM
detecting duplicate input in a cell leo Excel Worksheet Functions 0 January 22nd 07 07:28 AM
Detecting cell fill color Tony Rice Excel Discussion (Misc queries) 4 March 7th 05 03:48 PM


All times are GMT +1. The time now is 02:26 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"