From: Billy on 24 Apr 2010 14:39 i need a macro that will move the selection down 1 row if certain cells are selected. the cells are e13, e15, e17, e19, etc. If e13 is selected, i want the selection to go down 1 row, so that if e13 is selected, the selection changes to e14, and if e15 is slected, it changes to e16, etc. thanks! Tonso
From: Rick Rothstein on 24 Apr 2010 14:48 You waited a whole 4 minutes on a weekend before reposting your question... I've heard said that patience is a virtue<g> and keep in mind the people who answer questions on newsgroups are volunteers, not full time monitors, so you have to wait until someone who knows about the subject matter your question deals with comes along... that could be a couple of minutes, an hour or two or not until the next day. Anyway, I just posted a response against your question against your first message. -- Rick (MVP - Excel) "Billy" <wthomasss(a)hotmail.com> wrote in message news:9634bfef-e572-42a0-a956-80705461562e(a)h27g2000yqm.googlegroups.com... > i need a macro that will move the selection down 1 row if certain > cells are selected. the cells are e13, e15, e17, e19, etc. If e13 is > selected, i want the selection to go down 1 row, so that if e13 is > selected, the selection changes to e14, and if e15 is slected, it > changes to e16, etc. > > thanks! > > Tonso
From: Gord Dibben on 24 Apr 2010 14:56 Private Sub Worksheet_SelectionChange(ByVal Target As Range) Const WS_RANGE As String = "e13,e15,e17,e19" 'you add etc to the range On Error GoTo ws_exit Application.EnableEvents = False If Not Intersect(Target, Me.Range(WS_RANGE)) Is Nothing Then Target.Offset(1, 0).Select End If ws_exit: Application.EnableEvents = True End Sub Copy/paste this event code to your sheet module. Gord Dibben MS Excel MVP On Sat, 24 Apr 2010 11:39:28 -0700 (PDT), Billy <wthomasss(a)hotmail.com> wrote: >i need a macro that will move the selection down 1 row if certain >cells are selected. the cells are e13, e15, e17, e19, etc. If e13 is >selected, i want the selection to go down 1 row, so that if e13 is >selected, the selection changes to e14, and if e15 is slected, it >changes to e16, etc. > >thanks! > >Tonso
|
Pages: 1 Prev: Graphing a bounded region with a twist? Next: calculate number of days formula |