Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
excel 2003
How do I change cell colours rapidly in excel 2003 to create a flashing effect
|
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
excel 2003
Hi,
Before you do this consider that:- 1. Some people are sensitive to flashing lighst and it can induce fits. 2. Others may find it so irritating they would simply close the workbook and delete it and FWIW I fall into the second category So of you must put this code in a general module Option Explicit Public FlashRate As Double Sub Flash() If Range("A1").Interior.ColorIndex = 3 Then Range("A1").Interior.ColorIndex = 6 Else Range("A1").Interior.ColorIndex = 3 End If FlashRate = Now + TimeSerial(0, 0, 1) Application.OnTime FlashRate, "Flash", , True End Sub Sub StopBlink() Range("A1").Interior.ColorIndex = xlAutomatic Application.OnTime FlashRate, "Flash", , False End Sub Mike "col" wrote: How do I change cell colours rapidly in excel 2003 to create a flashing effect |
#3
Posted to microsoft.public.excel.misc
|
|||
|
|||
excel 2003
Hi, Mike.
I have a multicoloured, daily record (albeit 2007) used by four or five others. One particular entry falls into the "flashing cell" type of requirement to ensure it is completed each time the worksheet is brought up to date. I have the code you kindly provided which works fine, but what I would like to achieve is the flashing cell to be active immediately on opening the workbook rather than having to launch the macro. Can this be done? TIA, Ed "Mike H" wrote in message ... Hi, Before you do this consider that:- 1. Some people are sensitive to flashing lighst and it can induce fits. 2. Others may find it so irritating they would simply close the workbook and delete it and FWIW I fall into the second category So of you must put this code in a general module Option Explicit Public FlashRate As Double Sub Flash() If Range("A1").Interior.ColorIndex = 3 Then Range("A1").Interior.ColorIndex = 6 Else Range("A1").Interior.ColorIndex = 3 End If FlashRate = Now + TimeSerial(0, 0, 1) Application.OnTime FlashRate, "Flash", , True End Sub Sub StopBlink() Range("A1").Interior.ColorIndex = xlAutomatic Application.OnTime FlashRate, "Flash", , False End Sub Mike "col" wrote: How do I change cell colours rapidly in excel 2003 to create a flashing effect |
#4
Posted to microsoft.public.excel.misc
|
|||
|
|||
excel 2003
If you MUST have a blinking cell..............
Private Sub Worksheet_Activate() Flash End Sub You will also want to stop the blinking when the cell is filled in. Private Sub Worksheet_Change(ByVal Target As Excel.Range) On Error GoTo stoppit Application.EnableEvents = False If Target.Address = "$A$1" And Target.Value < "" Then StopBlink End If stoppit: Application.EnableEvents = True End Sub These go into the sheet module. I would not have blinking cells. You could do the same with a message box reminder that popped up when user activates the sheet. Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A1" End Sub Gord Dibben MS Excel MVP On Sat, 4 Jul 2009 14:14:53 +0100, "Ed O'Brien" wrote: Hi, Mike. I have a multicoloured, daily record (albeit 2007) used by four or five others. One particular entry falls into the "flashing cell" type of requirement to ensure it is completed each time the worksheet is brought up to date. I have the code you kindly provided which works fine, but what I would like to achieve is the flashing cell to be active immediately on opening the workbook rather than having to launch the macro. Can this be done? TIA, Ed "Mike H" wrote in message ... Hi, Before you do this consider that:- 1. Some people are sensitive to flashing lighst and it can induce fits. 2. Others may find it so irritating they would simply close the workbook and delete it and FWIW I fall into the second category So of you must put this code in a general module Option Explicit Public FlashRate As Double Sub Flash() If Range("A1").Interior.ColorIndex = 3 Then Range("A1").Interior.ColorIndex = 6 Else Range("A1").Interior.ColorIndex = 3 End If FlashRate = Now + TimeSerial(0, 0, 1) Application.OnTime FlashRate, "Flash", , True End Sub Sub StopBlink() Range("A1").Interior.ColorIndex = xlAutomatic Application.OnTime FlashRate, "Flash", , False End Sub Mike "col" wrote: How do I change cell colours rapidly in excel 2003 to create a flashing effect |
#5
Posted to microsoft.public.excel.misc
|
|||
|
|||
excel 2003
Thanks, Gord.
After a dozen times of the cell being missed and causing on-going errors later, a flashing cell I hope will cure it. I have been trying the Auto_Open and VB method shown in "Help" but I can't get either to work. Manually launching it works okay but hardly an answer. (Better to fill the dammed cell in than mess with macros)! The message method may work as long as the dolts don't cancel it and then forget...! I'll let you know how I get on. Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message ... If you MUST have a blinking cell.............. Private Sub Worksheet_Activate() Flash End Sub You will also want to stop the blinking when the cell is filled in. Private Sub Worksheet_Change(ByVal Target As Excel.Range) On Error GoTo stoppit Application.EnableEvents = False If Target.Address = "$A$1" And Target.Value < "" Then StopBlink End If stoppit: Application.EnableEvents = True End Sub These go into the sheet module. I would not have blinking cells. You could do the same with a message box reminder that popped up when user activates the sheet. Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A1" End Sub Gord Dibben MS Excel MVP On Sat, 4 Jul 2009 14:14:53 +0100, "Ed O'Brien" wrote: Hi, Mike. I have a multicoloured, daily record (albeit 2007) used by four or five others. One particular entry falls into the "flashing cell" type of requirement to ensure it is completed each time the worksheet is brought up to date. I have the code you kindly provided which works fine, but what I would like to achieve is the flashing cell to be active immediately on opening the workbook rather than having to launch the macro. Can this be done? TIA, Ed "Mike H" wrote in message ... Hi, Before you do this consider that:- 1. Some people are sensitive to flashing lighst and it can induce fits. 2. Others may find it so irritating they would simply close the workbook and delete it and FWIW I fall into the second category So of you must put this code in a general module Option Explicit Public FlashRate As Double Sub Flash() If Range("A1").Interior.ColorIndex = 3 Then Range("A1").Interior.ColorIndex = 6 Else Range("A1").Interior.ColorIndex = 3 End If FlashRate = Now + TimeSerial(0, 0, 1) Application.OnTime FlashRate, "Flash", , True End Sub Sub StopBlink() Range("A1").Interior.ColorIndex = xlAutomatic Application.OnTime FlashRate, "Flash", , False End Sub Mike "col" wrote: How do I change cell colours rapidly in excel 2003 to create a flashing effect |
#6
Posted to microsoft.public.excel.misc
|
|||
|
|||
excel 2003
Hi, Gord.
I gave up on the blinking cell idea and decided on the pop-up message, which is probably better. I'm running Excel 2007 but can't even get this to work. The file is .xlsm, all macros are enabled. I clicked "Sheet 1", inserted "Module 1" and I placed your script - Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A12" End Sub It is a blank (test) workbook with no other entries. I'm mystified. Any ideas? Thanks for your patience. Ed "Ed O'Brien" wrote in message ... Thanks, Gord. After a dozen times of the cell being missed and causing on-going errors later, a flashing cell I hope will cure it. I have been trying the Auto_Open and VB method shown in "Help" but I can't get either to work. Manually launching it works okay but hardly an answer. (Better to fill the dammed cell in than mess with macros)! The message method may work as long as the dolts don't cancel it and then forget...! I'll let you know how I get on. Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message ... If you MUST have a blinking cell.............. Private Sub Worksheet_Activate() Flash End Sub You will also want to stop the blinking when the cell is filled in. Private Sub Worksheet_Change(ByVal Target As Excel.Range) On Error GoTo stoppit Application.EnableEvents = False If Target.Address = "$A$1" And Target.Value < "" Then StopBlink End If stoppit: Application.EnableEvents = True End Sub These go into the sheet module. I would not have blinking cells. You could do the same with a message box reminder that popped up when user activates the sheet. Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A1" End Sub Gord Dibben MS Excel MVP On Sat, 4 Jul 2009 14:14:53 +0100, "Ed O'Brien" wrote: Hi, Mike. I have a multicoloured, daily record (albeit 2007) used by four or five others. One particular entry falls into the "flashing cell" type of requirement to ensure it is completed each time the worksheet is brought up to date. I have the code you kindly provided which works fine, but what I would like to achieve is the flashing cell to be active immediately on opening the workbook rather than having to launch the macro. Can this be done? TIA, Ed "Mike H" wrote in message ... Hi, Before you do this consider that:- 1. Some people are sensitive to flashing lighst and it can induce fits. 2. Others may find it so irritating they would simply close the workbook and delete it and FWIW I fall into the second category So of you must put this code in a general module Option Explicit Public FlashRate As Double Sub Flash() If Range("A1").Interior.ColorIndex = 3 Then Range("A1").Interior.ColorIndex = 6 Else Range("A1").Interior.ColorIndex = 3 End If FlashRate = Now + TimeSerial(0, 0, 1) Application.OnTime FlashRate, "Flash", , True End Sub Sub StopBlink() Range("A1").Interior.ColorIndex = xlAutomatic Application.OnTime FlashRate, "Flash", , False End Sub Mike "col" wrote: How do I change cell colours rapidly in excel 2003 to create a flashing effect |
#7
Posted to microsoft.public.excel.misc
|
|||
|
|||
excel 2003
Do not place the sheet event code into an inserted standard module.
Right-click on the sheet tab and "View Code". Copy/paste the code into that sheet module. OR open VBEditor and double-click on the sheet name. Gord On Sat, 4 Jul 2009 17:06:33 +0100, "Ed O'Brien" wrote: Hi, Gord. I gave up on the blinking cell idea and decided on the pop-up message, which is probably better. I'm running Excel 2007 but can't even get this to work. The file is .xlsm, all macros are enabled. I clicked "Sheet 1", inserted "Module 1" and I placed your script - Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A12" End Sub It is a blank (test) workbook with no other entries. I'm mystified. Any ideas? Thanks for your patience. Ed "Ed O'Brien" wrote in message ... Thanks, Gord. After a dozen times of the cell being missed and causing on-going errors later, a flashing cell I hope will cure it. I have been trying the Auto_Open and VB method shown in "Help" but I can't get either to work. Manually launching it works okay but hardly an answer. (Better to fill the dammed cell in than mess with macros)! The message method may work as long as the dolts don't cancel it and then forget...! I'll let you know how I get on. Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message ... If you MUST have a blinking cell.............. Private Sub Worksheet_Activate() Flash End Sub You will also want to stop the blinking when the cell is filled in. Private Sub Worksheet_Change(ByVal Target As Excel.Range) On Error GoTo stoppit Application.EnableEvents = False If Target.Address = "$A$1" And Target.Value < "" Then StopBlink End If stoppit: Application.EnableEvents = True End Sub These go into the sheet module. I would not have blinking cells. You could do the same with a message box reminder that popped up when user activates the sheet. Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A1" End Sub Gord Dibben MS Excel MVP On Sat, 4 Jul 2009 14:14:53 +0100, "Ed O'Brien" wrote: Hi, Mike. I have a multicoloured, daily record (albeit 2007) used by four or five others. One particular entry falls into the "flashing cell" type of requirement to ensure it is completed each time the worksheet is brought up to date. I have the code you kindly provided which works fine, but what I would like to achieve is the flashing cell to be active immediately on opening the workbook rather than having to launch the macro. Can this be done? TIA, Ed "Mike H" wrote in message ... Hi, Before you do this consider that:- 1. Some people are sensitive to flashing lighst and it can induce fits. 2. Others may find it so irritating they would simply close the workbook and delete it and FWIW I fall into the second category So of you must put this code in a general module Option Explicit Public FlashRate As Double Sub Flash() If Range("A1").Interior.ColorIndex = 3 Then Range("A1").Interior.ColorIndex = 6 Else Range("A1").Interior.ColorIndex = 3 End If FlashRate = Now + TimeSerial(0, 0, 1) Application.OnTime FlashRate, "Flash", , True End Sub Sub StopBlink() Range("A1").Interior.ColorIndex = xlAutomatic Application.OnTime FlashRate, "Flash", , False End Sub Mike "col" wrote: How do I change cell colours rapidly in excel 2003 to create a flashing effect |
#8
Posted to microsoft.public.excel.misc
|
|||
|
|||
excel 2003
Thanks, Gord.
Yes, I did that. As far as I can tell, I've done nothing wrong, but then I am getting on a bit! I click the Developer tab. (All macros are enabled under "Macro Security". The Workbook location is also) "Trusted". I click "Visual Basic" I right click "Sheet 1 (Sheet1)" I click "View Code" I copy/paste your script (which I know is accurate). I have tried with both "Workbook" and "General" headings. I click the 'Save' icon. I am using a blank workbook I have even added a Sheet 2 and tried it n that without success. Thanks again for your patience. Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message ... Do not place the sheet event code into an inserted standard module. Right-click on the sheet tab and "View Code". Copy/paste the code into that sheet module. OR open VBEditor and double-click on the sheet name. Gord On Sat, 4 Jul 2009 17:06:33 +0100, "Ed O'Brien" wrote: Hi, Gord. I gave up on the blinking cell idea and decided on the pop-up message, which is probably better. I'm running Excel 2007 but can't even get this to work. The file is .xlsm, all macros are enabled. I clicked "Sheet 1", inserted "Module 1" and I placed your script - Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A12" End Sub It is a blank (test) workbook with no other entries. I'm mystified. Any ideas? Thanks for your patience. Ed "Ed O'Brien" wrote in message .. . Thanks, Gord. After a dozen times of the cell being missed and causing on-going errors later, a flashing cell I hope will cure it. I have been trying the Auto_Open and VB method shown in "Help" but I can't get either to work. Manually launching it works okay but hardly an answer. (Better to fill the dammed cell in than mess with macros)! The message method may work as long as the dolts don't cancel it and then forget...! I'll let you know how I get on. Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message ... If you MUST have a blinking cell.............. Private Sub Worksheet_Activate() Flash End Sub You will also want to stop the blinking when the cell is filled in. Private Sub Worksheet_Change(ByVal Target As Excel.Range) On Error GoTo stoppit Application.EnableEvents = False If Target.Address = "$A$1" And Target.Value < "" Then StopBlink End If stoppit: Application.EnableEvents = True End Sub These go into the sheet module. I would not have blinking cells. You could do the same with a message box reminder that popped up when user activates the sheet. Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A1" End Sub Gord Dibben MS Excel MVP On Sat, 4 Jul 2009 14:14:53 +0100, "Ed O'Brien" wrote: Hi, Mike. I have a multicoloured, daily record (albeit 2007) used by four or five others. One particular entry falls into the "flashing cell" type of requirement to ensure it is completed each time the worksheet is brought up to date. I have the code you kindly provided which works fine, but what I would like to achieve is the flashing cell to be active immediately on opening the workbook rather than having to launch the macro. Can this be done? TIA, Ed "Mike H" wrote in message ... Hi, Before you do this consider that:- 1. Some people are sensitive to flashing lighst and it can induce fits. 2. Others may find it so irritating they would simply close the workbook and delete it and FWIW I fall into the second category So of you must put this code in a general module Option Explicit Public FlashRate As Double Sub Flash() If Range("A1").Interior.ColorIndex = 3 Then Range("A1").Interior.ColorIndex = 6 Else Range("A1").Interior.ColorIndex = 3 End If FlashRate = Now + TimeSerial(0, 0, 1) Application.OnTime FlashRate, "Flash", , True End Sub Sub StopBlink() Range("A1").Interior.ColorIndex = xlAutomatic Application.OnTime FlashRate, "Flash", , False End Sub Mike "col" wrote: How do I change cell colours rapidly in excel 2003 to create a flashing effect |
#9
Posted to microsoft.public.excel.misc
|
|||
|
|||
excel 2003
Hi, Gord.
After adding a second sheet, changing worksheets brings up the message box when a sheet is opened. However, when the book is first opened, it fails. As there is only one sheet in the workbook in question, the message will never display. Is there a code to activate the message as soon as the workbook is opened? TIA. Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message ... Do not place the sheet event code into an inserted standard module. Right-click on the sheet tab and "View Code". Copy/paste the code into that sheet module. OR open VBEditor and double-click on the sheet name. Gord On Sat, 4 Jul 2009 17:06:33 +0100, "Ed O'Brien" wrote: Hi, Gord. I gave up on the blinking cell idea and decided on the pop-up message, which is probably better. I'm running Excel 2007 but can't even get this to work. The file is .xlsm, all macros are enabled. I clicked "Sheet 1", inserted "Module 1" and I placed your script - Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A12" End Sub It is a blank (test) workbook with no other entries. I'm mystified. Any ideas? Thanks for your patience. Ed "Ed O'Brien" wrote in message .. . Thanks, Gord. After a dozen times of the cell being missed and causing on-going errors later, a flashing cell I hope will cure it. I have been trying the Auto_Open and VB method shown in "Help" but I can't get either to work. Manually launching it works okay but hardly an answer. (Better to fill the dammed cell in than mess with macros)! The message method may work as long as the dolts don't cancel it and then forget...! I'll let you know how I get on. Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message ... If you MUST have a blinking cell.............. Private Sub Worksheet_Activate() Flash End Sub You will also want to stop the blinking when the cell is filled in. Private Sub Worksheet_Change(ByVal Target As Excel.Range) On Error GoTo stoppit Application.EnableEvents = False If Target.Address = "$A$1" And Target.Value < "" Then StopBlink End If stoppit: Application.EnableEvents = True End Sub These go into the sheet module. I would not have blinking cells. You could do the same with a message box reminder that popped up when user activates the sheet. Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A1" End Sub Gord Dibben MS Excel MVP On Sat, 4 Jul 2009 14:14:53 +0100, "Ed O'Brien" wrote: Hi, Mike. I have a multicoloured, daily record (albeit 2007) used by four or five others. One particular entry falls into the "flashing cell" type of requirement to ensure it is completed each time the worksheet is brought up to date. I have the code you kindly provided which works fine, but what I would like to achieve is the flashing cell to be active immediately on opening the workbook rather than having to launch the macro. Can this be done? TIA, Ed "Mike H" wrote in message ... Hi, Before you do this consider that:- 1. Some people are sensitive to flashing lighst and it can induce fits. 2. Others may find it so irritating they would simply close the workbook and delete it and FWIW I fall into the second category So of you must put this code in a general module Option Explicit Public FlashRate As Double Sub Flash() If Range("A1").Interior.ColorIndex = 3 Then Range("A1").Interior.ColorIndex = 6 Else Range("A1").Interior.ColorIndex = 3 End If FlashRate = Now + TimeSerial(0, 0, 1) Application.OnTime FlashRate, "Flash", , True End Sub Sub StopBlink() Range("A1").Interior.ColorIndex = xlAutomatic Application.OnTime FlashRate, "Flash", , False End Sub Mike "col" wrote: How do I change cell colours rapidly in excel 2003 to create a flashing effect |
#10
Posted to microsoft.public.excel.misc
|
|||
|
|||
excel 2003
With a one sheet workbook place this code in Thisworkbook module.
Private Sub Workbook_Open() MsgBox "Don't forget to fill in A12" End Sub Gord On Sun, 5 Jul 2009 18:20:11 +0100, "Ed O'Brien" wrote: Hi, Gord. After adding a second sheet, changing worksheets brings up the message box when a sheet is opened. However, when the book is first opened, it fails. As there is only one sheet in the workbook in question, the message will never display. Is there a code to activate the message as soon as the workbook is opened? TIA. Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message .. . Do not place the sheet event code into an inserted standard module. Right-click on the sheet tab and "View Code". Copy/paste the code into that sheet module. OR open VBEditor and double-click on the sheet name. Gord On Sat, 4 Jul 2009 17:06:33 +0100, "Ed O'Brien" wrote: Hi, Gord. I gave up on the blinking cell idea and decided on the pop-up message, which is probably better. I'm running Excel 2007 but can't even get this to work. The file is .xlsm, all macros are enabled. I clicked "Sheet 1", inserted "Module 1" and I placed your script - Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A12" End Sub It is a blank (test) workbook with no other entries. I'm mystified. Any ideas? Thanks for your patience. Ed "Ed O'Brien" wrote in message . .. Thanks, Gord. After a dozen times of the cell being missed and causing on-going errors later, a flashing cell I hope will cure it. I have been trying the Auto_Open and VB method shown in "Help" but I can't get either to work. Manually launching it works okay but hardly an answer. (Better to fill the dammed cell in than mess with macros)! The message method may work as long as the dolts don't cancel it and then forget...! I'll let you know how I get on. Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message ... If you MUST have a blinking cell.............. Private Sub Worksheet_Activate() Flash End Sub You will also want to stop the blinking when the cell is filled in. Private Sub Worksheet_Change(ByVal Target As Excel.Range) On Error GoTo stoppit Application.EnableEvents = False If Target.Address = "$A$1" And Target.Value < "" Then StopBlink End If stoppit: Application.EnableEvents = True End Sub These go into the sheet module. I would not have blinking cells. You could do the same with a message box reminder that popped up when user activates the sheet. Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A1" End Sub Gord Dibben MS Excel MVP On Sat, 4 Jul 2009 14:14:53 +0100, "Ed O'Brien" wrote: Hi, Mike. I have a multicoloured, daily record (albeit 2007) used by four or five others. One particular entry falls into the "flashing cell" type of requirement to ensure it is completed each time the worksheet is brought up to date. I have the code you kindly provided which works fine, but what I would like to achieve is the flashing cell to be active immediately on opening the workbook rather than having to launch the macro. Can this be done? TIA, Ed "Mike H" wrote in message ... Hi, Before you do this consider that:- 1. Some people are sensitive to flashing lighst and it can induce fits. 2. Others may find it so irritating they would simply close the workbook and delete it and FWIW I fall into the second category So of you must put this code in a general module Option Explicit Public FlashRate As Double Sub Flash() If Range("A1").Interior.ColorIndex = 3 Then Range("A1").Interior.ColorIndex = 6 Else Range("A1").Interior.ColorIndex = 3 End If FlashRate = Now + TimeSerial(0, 0, 1) Application.OnTime FlashRate, "Flash", , True End Sub Sub StopBlink() Range("A1").Interior.ColorIndex = xlAutomatic Application.OnTime FlashRate, "Flash", , False End Sub Mike "col" wrote: How do I change cell colours rapidly in excel 2003 to create a flashing effect |
#11
Posted to microsoft.public.excel.misc
|
|||
|
|||
excel 2003
Thanks a million, Gord.
Works fine. Kind regards, Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message ... With a one sheet workbook place this code in Thisworkbook module. Private Sub Workbook_Open() MsgBox "Don't forget to fill in A12" End Sub Gord On Sun, 5 Jul 2009 18:20:11 +0100, "Ed O'Brien" wrote: Hi, Gord. After adding a second sheet, changing worksheets brings up the message box when a sheet is opened. However, when the book is first opened, it fails. As there is only one sheet in the workbook in question, the message will never display. Is there a code to activate the message as soon as the workbook is opened? TIA. Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message . .. Do not place the sheet event code into an inserted standard module. Right-click on the sheet tab and "View Code". Copy/paste the code into that sheet module. OR open VBEditor and double-click on the sheet name. Gord On Sat, 4 Jul 2009 17:06:33 +0100, "Ed O'Brien" wrote: Hi, Gord. I gave up on the blinking cell idea and decided on the pop-up message, which is probably better. I'm running Excel 2007 but can't even get this to work. The file is .xlsm, all macros are enabled. I clicked "Sheet 1", inserted "Module 1" and I placed your script - Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A12" End Sub It is a blank (test) workbook with no other entries. I'm mystified. Any ideas? Thanks for your patience. Ed "Ed O'Brien" wrote in message .. . Thanks, Gord. After a dozen times of the cell being missed and causing on-going errors later, a flashing cell I hope will cure it. I have been trying the Auto_Open and VB method shown in "Help" but I can't get either to work. Manually launching it works okay but hardly an answer. (Better to fill the dammed cell in than mess with macros)! The message method may work as long as the dolts don't cancel it and then forget...! I'll let you know how I get on. Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message ... If you MUST have a blinking cell.............. Private Sub Worksheet_Activate() Flash End Sub You will also want to stop the blinking when the cell is filled in. Private Sub Worksheet_Change(ByVal Target As Excel.Range) On Error GoTo stoppit Application.EnableEvents = False If Target.Address = "$A$1" And Target.Value < "" Then StopBlink End If stoppit: Application.EnableEvents = True End Sub These go into the sheet module. I would not have blinking cells. You could do the same with a message box reminder that popped up when user activates the sheet. Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A1" End Sub Gord Dibben MS Excel MVP On Sat, 4 Jul 2009 14:14:53 +0100, "Ed O'Brien" wrote: Hi, Mike. I have a multicoloured, daily record (albeit 2007) used by four or five others. One particular entry falls into the "flashing cell" type of requirement to ensure it is completed each time the worksheet is brought up to date. I have the code you kindly provided which works fine, but what I would like to achieve is the flashing cell to be active immediately on opening the workbook rather than having to launch the macro. Can this be done? TIA, Ed "Mike H" wrote in message ... Hi, Before you do this consider that:- 1. Some people are sensitive to flashing lighst and it can induce fits. 2. Others may find it so irritating they would simply close the workbook and delete it and FWIW I fall into the second category So of you must put this code in a general module Option Explicit Public FlashRate As Double Sub Flash() If Range("A1").Interior.ColorIndex = 3 Then Range("A1").Interior.ColorIndex = 6 Else Range("A1").Interior.ColorIndex = 3 End If FlashRate = Now + TimeSerial(0, 0, 1) Application.OnTime FlashRate, "Flash", , True End Sub Sub StopBlink() Range("A1").Interior.ColorIndex = xlAutomatic Application.OnTime FlashRate, "Flash", , False End Sub Mike "col" wrote: How do I change cell colours rapidly in excel 2003 to create a flashing effect |
#12
Posted to microsoft.public.excel.misc
|
|||
|
|||
excel 2003
Hi, Gord.
I hope you don't mind me atking up a little more of your time. Having got this to work fine, now. As a matter of interest - is it possible to format the message box? TIA Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message ... With a one sheet workbook place this code in Thisworkbook module. Private Sub Workbook_Open() MsgBox "Don't forget to fill in A12" End Sub Gord On Sun, 5 Jul 2009 18:20:11 +0100, "Ed O'Brien" wrote: Hi, Gord. After adding a second sheet, changing worksheets brings up the message box when a sheet is opened. However, when the book is first opened, it fails. As there is only one sheet in the workbook in question, the message will never display. Is there a code to activate the message as soon as the workbook is opened? TIA. Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message . .. Do not place the sheet event code into an inserted standard module. Right-click on the sheet tab and "View Code". Copy/paste the code into that sheet module. OR open VBEditor and double-click on the sheet name. Gord On Sat, 4 Jul 2009 17:06:33 +0100, "Ed O'Brien" wrote: Hi, Gord. I gave up on the blinking cell idea and decided on the pop-up message, which is probably better. I'm running Excel 2007 but can't even get this to work. The file is .xlsm, all macros are enabled. I clicked "Sheet 1", inserted "Module 1" and I placed your script - Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A12" End Sub It is a blank (test) workbook with no other entries. I'm mystified. Any ideas? Thanks for your patience. Ed "Ed O'Brien" wrote in message .. . Thanks, Gord. After a dozen times of the cell being missed and causing on-going errors later, a flashing cell I hope will cure it. I have been trying the Auto_Open and VB method shown in "Help" but I can't get either to work. Manually launching it works okay but hardly an answer. (Better to fill the dammed cell in than mess with macros)! The message method may work as long as the dolts don't cancel it and then forget...! I'll let you know how I get on. Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message ... If you MUST have a blinking cell.............. Private Sub Worksheet_Activate() Flash End Sub You will also want to stop the blinking when the cell is filled in. Private Sub Worksheet_Change(ByVal Target As Excel.Range) On Error GoTo stoppit Application.EnableEvents = False If Target.Address = "$A$1" And Target.Value < "" Then StopBlink End If stoppit: Application.EnableEvents = True End Sub These go into the sheet module. I would not have blinking cells. You could do the same with a message box reminder that popped up when user activates the sheet. Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A1" End Sub Gord Dibben MS Excel MVP On Sat, 4 Jul 2009 14:14:53 +0100, "Ed O'Brien" wrote: Hi, Mike. I have a multicoloured, daily record (albeit 2007) used by four or five others. One particular entry falls into the "flashing cell" type of requirement to ensure it is completed each time the worksheet is brought up to date. I have the code you kindly provided which works fine, but what I would like to achieve is the flashing cell to be active immediately on opening the workbook rather than having to launch the macro. Can this be done? TIA, Ed "Mike H" wrote in message ... Hi, Before you do this consider that:- 1. Some people are sensitive to flashing lighst and it can induce fits. 2. Others may find it so irritating they would simply close the workbook and delete it and FWIW I fall into the second category So of you must put this code in a general module Option Explicit Public FlashRate As Double Sub Flash() If Range("A1").Interior.ColorIndex = 3 Then Range("A1").Interior.ColorIndex = 6 Else Range("A1").Interior.ColorIndex = 3 End If FlashRate = Now + TimeSerial(0, 0, 1) Application.OnTime FlashRate, "Flash", , True End Sub Sub StopBlink() Range("A1").Interior.ColorIndex = xlAutomatic Application.OnTime FlashRate, "Flash", , False End Sub Mike "col" wrote: How do I change cell colours rapidly in excel 2003 to create a flashing effect |
#13
Posted to microsoft.public.excel.misc
|
|||
|
|||
excel 2003
No.
You would have to build a customized UserForm and call it up. Gord On Mon, 6 Jul 2009 14:26:48 +0100, "Ed O'Brien" wrote: Hi, Gord. I hope you don't mind me atking up a little more of your time. Having got this to work fine, now. As a matter of interest - is it possible to format the message box? TIA Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message .. . With a one sheet workbook place this code in Thisworkbook module. Private Sub Workbook_Open() MsgBox "Don't forget to fill in A12" End Sub Gord On Sun, 5 Jul 2009 18:20:11 +0100, "Ed O'Brien" wrote: Hi, Gord. After adding a second sheet, changing worksheets brings up the message box when a sheet is opened. However, when the book is first opened, it fails. As there is only one sheet in the workbook in question, the message will never display. Is there a code to activate the message as soon as the workbook is opened? TIA. Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message ... Do not place the sheet event code into an inserted standard module. Right-click on the sheet tab and "View Code". Copy/paste the code into that sheet module. OR open VBEditor and double-click on the sheet name. Gord On Sat, 4 Jul 2009 17:06:33 +0100, "Ed O'Brien" wrote: Hi, Gord. I gave up on the blinking cell idea and decided on the pop-up message, which is probably better. I'm running Excel 2007 but can't even get this to work. The file is .xlsm, all macros are enabled. I clicked "Sheet 1", inserted "Module 1" and I placed your script - Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A12" End Sub It is a blank (test) workbook with no other entries. I'm mystified. Any ideas? Thanks for your patience. Ed "Ed O'Brien" wrote in message . .. Thanks, Gord. After a dozen times of the cell being missed and causing on-going errors later, a flashing cell I hope will cure it. I have been trying the Auto_Open and VB method shown in "Help" but I can't get either to work. Manually launching it works okay but hardly an answer. (Better to fill the dammed cell in than mess with macros)! The message method may work as long as the dolts don't cancel it and then forget...! I'll let you know how I get on. Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message ... If you MUST have a blinking cell.............. Private Sub Worksheet_Activate() Flash End Sub You will also want to stop the blinking when the cell is filled in. Private Sub Worksheet_Change(ByVal Target As Excel.Range) On Error GoTo stoppit Application.EnableEvents = False If Target.Address = "$A$1" And Target.Value < "" Then StopBlink End If stoppit: Application.EnableEvents = True End Sub These go into the sheet module. I would not have blinking cells. You could do the same with a message box reminder that popped up when user activates the sheet. Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A1" End Sub Gord Dibben MS Excel MVP On Sat, 4 Jul 2009 14:14:53 +0100, "Ed O'Brien" wrote: Hi, Mike. I have a multicoloured, daily record (albeit 2007) used by four or five others. One particular entry falls into the "flashing cell" type of requirement to ensure it is completed each time the worksheet is brought up to date. I have the code you kindly provided which works fine, but what I would like to achieve is the flashing cell to be active immediately on opening the workbook rather than having to launch the macro. Can this be done? TIA, Ed "Mike H" wrote in message ... Hi, Before you do this consider that:- 1. Some people are sensitive to flashing lighst and it can induce fits. 2. Others may find it so irritating they would simply close the workbook and delete it and FWIW I fall into the second category So of you must put this code in a general module Option Explicit Public FlashRate As Double Sub Flash() If Range("A1").Interior.ColorIndex = 3 Then Range("A1").Interior.ColorIndex = 6 Else Range("A1").Interior.ColorIndex = 3 End If FlashRate = Now + TimeSerial(0, 0, 1) Application.OnTime FlashRate, "Flash", , True End Sub Sub StopBlink() Range("A1").Interior.ColorIndex = xlAutomatic Application.OnTime FlashRate, "Flash", , False End Sub Mike "col" wrote: How do I change cell colours rapidly in excel 2003 to create a flashing effect |
#14
Posted to microsoft.public.excel.misc
|
|||
|
|||
excel 2003
Thanks, Gord.
Looks a bit over my head, I'm afraid. Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message ... No. You would have to build a customized UserForm and call it up. Gord On Mon, 6 Jul 2009 14:26:48 +0100, "Ed O'Brien" wrote: Hi, Gord. I hope you don't mind me atking up a little more of your time. Having got this to work fine, now. As a matter of interest - is it possible to format the message box? TIA Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message . .. With a one sheet workbook place this code in Thisworkbook module. Private Sub Workbook_Open() MsgBox "Don't forget to fill in A12" End Sub Gord On Sun, 5 Jul 2009 18:20:11 +0100, "Ed O'Brien" wrote: Hi, Gord. After adding a second sheet, changing worksheets brings up the message box when a sheet is opened. However, when the book is first opened, it fails. As there is only one sheet in the workbook in question, the message will never display. Is there a code to activate the message as soon as the workbook is opened? TIA. Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message m... Do not place the sheet event code into an inserted standard module. Right-click on the sheet tab and "View Code". Copy/paste the code into that sheet module. OR open VBEditor and double-click on the sheet name. Gord On Sat, 4 Jul 2009 17:06:33 +0100, "Ed O'Brien" wrote: Hi, Gord. I gave up on the blinking cell idea and decided on the pop-up message, which is probably better. I'm running Excel 2007 but can't even get this to work. The file is .xlsm, all macros are enabled. I clicked "Sheet 1", inserted "Module 1" and I placed your script - Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A12" End Sub It is a blank (test) workbook with no other entries. I'm mystified. Any ideas? Thanks for your patience. Ed "Ed O'Brien" wrote in message ... Thanks, Gord. After a dozen times of the cell being missed and causing on-going errors later, a flashing cell I hope will cure it. I have been trying the Auto_Open and VB method shown in "Help" but I can't get either to work. Manually launching it works okay but hardly an answer. (Better to fill the dammed cell in than mess with macros)! The message method may work as long as the dolts don't cancel it and then forget...! I'll let you know how I get on. Ed "Gord Dibben" <gorddibbATshawDOTca wrote in message ... If you MUST have a blinking cell.............. Private Sub Worksheet_Activate() Flash End Sub You will also want to stop the blinking when the cell is filled in. Private Sub Worksheet_Change(ByVal Target As Excel.Range) On Error GoTo stoppit Application.EnableEvents = False If Target.Address = "$A$1" And Target.Value < "" Then StopBlink End If stoppit: Application.EnableEvents = True End Sub These go into the sheet module. I would not have blinking cells. You could do the same with a message box reminder that popped up when user activates the sheet. Private Sub Worksheet_Activate() MsgBox "Don't forget to fill in A1" End Sub Gord Dibben MS Excel MVP On Sat, 4 Jul 2009 14:14:53 +0100, "Ed O'Brien" wrote: Hi, Mike. I have a multicoloured, daily record (albeit 2007) used by four or five others. One particular entry falls into the "flashing cell" type of requirement to ensure it is completed each time the worksheet is brought up to date. I have the code you kindly provided which works fine, but what I would like to achieve is the flashing cell to be active immediately on opening the workbook rather than having to launch the macro. Can this be done? TIA, Ed "Mike H" wrote in message ... Hi, Before you do this consider that:- 1. Some people are sensitive to flashing lighst and it can induce fits. 2. Others may find it so irritating they would simply close the workbook and delete it and FWIW I fall into the second category So of you must put this code in a general module Option Explicit Public FlashRate As Double Sub Flash() If Range("A1").Interior.ColorIndex = 3 Then Range("A1").Interior.ColorIndex = 6 Else Range("A1").Interior.ColorIndex = 3 End If FlashRate = Now + TimeSerial(0, 0, 1) Application.OnTime FlashRate, "Flash", , True End Sub Sub StopBlink() Range("A1").Interior.ColorIndex = xlAutomatic Application.OnTime FlashRate, "Flash", , False End Sub Mike "col" wrote: How do I change cell colours rapidly in excel 2003 to create a flashing effect |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Excel 2003 attachments open and show only empty cells when openedvia Outlook 2003? | Excel Discussion (Misc queries) | |||
Convert Excel 2003 spreadsheet into Outlook Contacts table 2003 | Excel Discussion (Misc queries) | |||
import Excel 2003 file into Outlook 2003 - NO NAMED RANGES?? | Excel Discussion (Misc queries) | |||
Copying Excel 2003 Selection into Outlook 2003 HTML E-Mail Message | Excel Discussion (Misc queries) | |||
Excel 2003 Database Driver Visual FoxPro 7 on Server 2003. | Excel Discussion (Misc queries) |