LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,290
Default preventing reference to a particular cell

Jim O,

You might be able to get close with the following
code entered into the worksheet module.
There are always ways around code like this, but it could help...
'----------------------
Private Sub Worksheet_Change(ByVal Target As Range)
On Error GoTo ErrorHandler
Application.EnableEvents = False
'Change range address to the appropriate cells.
If Not Application.Intersect(Target(1), Me.Range("B5:D10")) Is Nothing Then
If Asc(Target(1).Formula) = 61 Then Target(1).Formula = "No formulas here" 'or vbNullString
End If
ErrorHandler:
Application.EnableEvents = True
End Sub
'------------------------

Jim Cone
San Francisco, USA


"Jim O"
wrote in message
...
Chip
Is there a way to prevent the active cell from being a formula? Data entry
only?--
Jim O



 
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
Preventing data input until a particular cell is used R Excel Worksheet Functions 3 September 4th 09 01:26 PM
Preventing Multi Cell Selection Michael Excel Dude Excel Discussion (Misc queries) 2 September 5th 06 02:18 PM
preventing a cell from being referenced? Eijah626 Excel Discussion (Misc queries) 1 November 28th 05 07:23 PM
Preventing cell from being empty Kobus Excel Programming 2 April 15th 05 08:08 AM
Preventing cell contents from printing Blair Scanlan Excel Discussion (Misc queries) 5 December 20th 04 12:39 AM


All times are GMT +1. The time now is 08:40 AM.

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"