Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
enter text in cell just by selecting cell
When i select a cell i would like the letter X or a number to automatically
insert. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
enter text in cell just by selecting cell
Reference the following thread:
"Macro to Enter text" from 12/13/2007 "dlyon" wrote in message ... When i select a cell i would like the letter X or a number to automatically insert. |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
enter text in cell just by selecting cell
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Const WS_RANGE As String = "A1:A10" Dim cell As Range On Error GoTo ws_exit: Application.EnableEvents = False If Not Intersect(Target, Me.Range(WS_RANGE)) Is Nothing Then For Each cell In Target cell.Value = "X" Next cell End If ws_exit: Application.EnableEvents = True End Sub This is sheet event code. Right-click on the sheet tab and "View Code" Copy/paste into that sheet module. Alt + q to return your sheet. Adjust the range A1:A10 and the value "X" to suit. Gord Dibben MS Excel MVP On Sat, 15 Dec 2007 10:10:01 -0800, dlyon wrote: When i select a cell i would like the letter X or a number to automatically insert. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Hit enter in cell & move text down in cell, not go to cell below. | Excel Worksheet Functions | |||
ENTER TEXT IN A CELL AND GET A VALUE FROM ANOTHER CELL | Excel Worksheet Functions | |||
Enter text in a cell to return a text value in same cell | Excel Discussion (Misc queries) | |||
Copying text from website OR selecting and coping certain text within a cell | Excel Programming | |||
Enter value in cell by selecting cell. | Excel Discussion (Misc queries) |