Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8
Default Can a cell be turned on and off?

My cell to like this

=(A2+A3) I would like this total to only be active if I click on the cell.

In other words can the cell be turned on or off by just clicking on it?
--
Joe
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22,906
Default Can a cell be turned on and off?

Not without using VBA

You want the value toggled on/off or just toggle the font white or black?

This event code will toggle the formula on or off.

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Const myRange As String = "A1"
On Error GoTo stoppit
Application.EnableEvents = False
If Not Intersect(Target, Me.Range(myRange)) Is Nothing Then
With Target
If .Value = "" Then
.Formula = "=A2+A3"
Else
.Value = ""
End If
End With
End If
stoppit:
Application.EnableEvents = True
End Sub


Gord Dibben MS Excel MVP

On Mon, 1 Mar 2010 14:20:02 -0800, painter50
wrote:

My cell to like this

=(A2+A3) I would like this total to only be active if I click on the cell.

In other words can the cell be turned on or off by just clicking on it?


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
MACROs Are Turned Off DOUG ECKERT[_2_] Excel Discussion (Misc queries) 1 December 2nd 08 10:44 PM
can you format a cell so that formulas will be turned off Brian Excel Discussion (Misc queries) 6 February 15th 08 12:12 AM
How can I edit cell notes while track changes is turned on? bluebird Excel Worksheet Functions 0 August 22nd 06 07:01 PM
Why am I getting XXX error in text cell with word wrap turned on? HMF Excel Discussion (Misc queries) 2 March 16th 06 12:44 AM
Worksheet has turned TeeJay Excel Worksheet Functions 0 January 12th 06 08:44 AM


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

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

About Us

"It's about Microsoft Excel"