Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Can I use conditional formatting for this neat thing?
I had an idea this morning to make my user's lives easier for a particular
spreadsheet. The idea is to have a text string appear in cell C2 if it's empty, and that is: "Please enter value here ..." And then when user enters a value, they'll see the data they've entered into that cell until/unless they empty the cell. Is this possible to do? Again, I've just spent a considerable amount of time in the archives searching for conditional formatting examples with text strings, but nothing comes up that's pertinent. TIA. :oD |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Can I use conditional formatting for this neat thing?
try this:
right click on the sheet tab where you want C2 to change and select view code from the menu(on the bottom) then paste this code into the window Private Sub Worksheet_SelectionChange(ByVal Target As Range) If Range("C2") = Empty Then Range("C2").Value = "Please enter a value here..." End If End Sub Sandy StargateFanFromWork wrote: I had an idea this morning to make my user's lives easier for a particular spreadsheet. The idea is to have a text string appear in cell C2 if it's empty, and that is: "Please enter value here ..." And then when user enters a value, they'll see the data they've entered into that cell until/unless they empty the cell. Is this possible to do? Again, I've just spent a considerable amount of time in the archives searching for conditional formatting examples with text strings, but nothing comes up that's pertinent. TIA. :oD |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Can I use conditional formatting for this neat thing?
Not a good sign. This didn't work. I put the code exactly as below into
the vba in the window for this sheet, but nothing. Did this work for you? Tx. :oD "Sandy" wrote in message oups.com... try this: right click on the sheet tab where you want C2 to change and select view code from the menu(on the bottom) then paste this code into the window Private Sub Worksheet_SelectionChange(ByVal Target As Range) If Range("C2") = Empty Then Range("C2").Value = "Please enter a value here..." End If End Sub Sandy StargateFanFromWork wrote: I had an idea this morning to make my user's lives easier for a particular spreadsheet. The idea is to have a text string appear in cell C2 if it's empty, and that is: "Please enter value here ..." And then when user enters a value, they'll see the data they've entered into that cell until/unless they empty the cell. Is this possible to do? Again, I've just spent a considerable amount of time in the archives searching for conditional formatting examples with text strings, but nothing comes up that's pertinent. TIA. :oD |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Can I use conditional formatting for this neat thing?
StargateFanFromWork wrote:
Not a good sign. This didn't work. I put the code exactly as below into the vba in the window for this sheet, but nothing. The code works. Did you select a cell in the sheet after placing the code? |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Can I use conditional formatting for this neat thing?
Also make sure that your EnableEvents is active, run this code to make
sure it is Place this in the same way you pasted the last code, to run it press alt + F8 together and select Myenable and click run, this will allow worksheet/workbook events to run. Sub Myenable() Application.EnableEvents = True End Sub Sandy StargateFanFromWork wrote: Not a good sign. This didn't work. I put the code exactly as below into the vba in the window for this sheet, but nothing. Did this work for you? Tx. :oD "Sandy" wrote in message oups.com... try this: right click on the sheet tab where you want C2 to change and select view code from the menu(on the bottom) then paste this code into the window Private Sub Worksheet_SelectionChange(ByVal Target As Range) If Range("C2") = Empty Then Range("C2").Value = "Please enter a value here..." End If End Sub Sandy StargateFanFromWork wrote: I had an idea this morning to make my user's lives easier for a particular spreadsheet. The idea is to have a text string appear in cell C2 if it's empty, and that is: "Please enter value here ..." And then when user enters a value, they'll see the data they've entered into that cell until/unless they empty the cell. Is this possible to do? Again, I've just spent a considerable amount of time in the archives searching for conditional formatting examples with text strings, but nothing comes up that's pertinent. TIA. :oD |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
Can I use conditional formatting for this neat thing?
Perfect!! Thank you, that's like magic. Enabling set everything in motion,
it seems. I set up the sheet so that it's ready to go with the text string showing. Since it's a locked template, each test shows the text is in place on launching and it prompts user on where to start in a simple, straightforward way. Gotta love Excel! <g Thanks. :oD "Sandy" wrote in message oups.com... Also make sure that your EnableEvents is active, run this code to make sure it is Place this in the same way you pasted the last code, to run it press alt + F8 together and select Myenable and click run, this will allow worksheet/workbook events to run. Sub Myenable() Application.EnableEvents = True End Sub Sandy StargateFanFromWork wrote: Not a good sign. This didn't work. I put the code exactly as below into the vba in the window for this sheet, but nothing. Did this work for you? Tx. :oD "Sandy" wrote in message oups.com... try this: right click on the sheet tab where you want C2 to change and select view code from the menu(on the bottom) then paste this code into the window Private Sub Worksheet_SelectionChange(ByVal Target As Range) If Range("C2") = Empty Then Range("C2").Value = "Please enter a value here..." End If End Sub Sandy StargateFanFromWork wrote: I had an idea this morning to make my user's lives easier for a particular spreadsheet. The idea is to have a text string appear in cell C2 if it's empty, and that is: "Please enter value here ..." And then when user enters a value, they'll see the data they've entered into that cell until/unless they empty the cell. Is this possible to do? Again, I've just spent a considerable amount of time in the archives searching for conditional formatting examples with text strings, but nothing comes up that's pertinent. TIA. :oD |
#7
Posted to microsoft.public.excel.programming
|
|||
|
|||
Can I use conditional formatting for this neat thing?
Woops, forgot to mention. Before user inputs a dollar amount, all
subsequent cells with dependent formulas show up as the confusing #VALUE!. It turned out extremely easy to set up conditional formatting to make the #VALUE! text disappear. I changed the regular font in cell so that it's the same colour as the cell background. In the conditional formatting, I tested out having cell value 0 with an actual font colour and the cell results show up as numbers in a sane and rational way once the user goes into the cell and inputs a dollar amount. Very kewl. Thanks for this, once again. :oD "StargateFanFromWork" wrote in message ... Perfect!! Thank you, that's like magic. Enabling set everything in motion, it seems. I set up the sheet so that it's ready to go with the text string showing. Since it's a locked template, each test shows the text is in place on launching and it prompts user on where to start in a simple, straightforward way. Gotta love Excel! <g Thanks. :oD "Sandy" wrote in message oups.com... Also make sure that your EnableEvents is active, run this code to make sure it is Place this in the same way you pasted the last code, to run it press alt + F8 together and select Myenable and click run, this will allow worksheet/workbook events to run. Sub Myenable() Application.EnableEvents = True End Sub Sandy StargateFanFromWork wrote: Not a good sign. This didn't work. I put the code exactly as below into the vba in the window for this sheet, but nothing. Did this work for you? Tx. :oD "Sandy" wrote in message oups.com... try this: right click on the sheet tab where you want C2 to change and select view code from the menu(on the bottom) then paste this code into the window Private Sub Worksheet_SelectionChange(ByVal Target As Range) If Range("C2") = Empty Then Range("C2").Value = "Please enter a value here..." End If End Sub Sandy StargateFanFromWork wrote: I had an idea this morning to make my user's lives easier for a particular spreadsheet. The idea is to have a text string appear in cell C2 if it's empty, and that is: "Please enter value here ..." And then when user enters a value, they'll see the data they've entered into that cell until/unless they empty the cell. Is this possible to do? Again, I've just spent a considerable amount of time in the archives searching for conditional formatting examples with text strings, but nothing comes up that's pertinent. TIA. :oD |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Neat Trick | Excel Discussion (Misc queries) | |||
Sharing a neat trick | Excel Discussion (Misc queries) | |||
get rid of formatting clipboard thing? | Excel Discussion (Misc queries) | |||
Writing neat code | Excel Programming | |||
Keeping macros neat | Excel Programming |