Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
macro on exit of field
Is there a way to run a macro on exiting a cell. For example if I answer Yes
in cell A4, then I would like it to automatically go to A10 on exiting A4. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
macro on exit of field
Put this in the appropriate Sheet Module.
Private Sub Worksheet_Change(ByVal Target As Range) If Target.Address = "$A$4" Then If Target = "Yes" Then Range("A10").Select End If End Sub Hth, Merjet |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
macro on exit of field
You can use the on change code of the worksheet. Right click the sheet tab
and select View Code. I have made the code easy to expand and modify. Paste the following... Private Sub Worksheet_Change(ByVal Target As Range) Select Case Target.Address Case "$A$4" If UCase(Target.Value) = "YES" Then Range("A10").Select Case "$A$10" MsgBox "Change " & Target.Address End Select End Sub -- HTH... Jim Thomlinson "Manuel Murieta" wrote: Is there a way to run a macro on exiting a cell. For example if I answer Yes in cell A4, then I would like it to automatically go to A10 on exiting A4. |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
macro on exit of field
This was already answered in a previous post.
In article , "Manuel Murieta" wrote: Is there a way to run a macro on exiting a cell. For example if I answer Yes in cell A4, then I would like it to automatically go to A10 on exiting A4. |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
macro on exit of field
See responses to your same posting in public.excel news group.
Gord Dibben MS Excel MVP On Tue, 13 Feb 2007 12:41:25 -0500, "Manuel Murieta" wrote: Is there a way to run a macro on exiting a cell. For example if I answer Yes in cell A4, then I would like it to automatically go to A10 on exiting A4. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Run a macro on exit | Excel Programming | |||
Run macro on exit | Excel Discussion (Misc queries) | |||
macro wants to exit excel | Excel Discussion (Misc queries) | |||
Exit via macro only? | Excel Discussion (Misc queries) | |||
on exit macro | Excel Discussion (Misc queries) |