Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 01-30-2017, 12:12 AM
Kev Kev is offline Help with UserForm Windows 7 64bit Help with UserForm Office 2016
Novice
 
Join Date: Jan 2017
Posts: 7
Kev is on a distinguished road
Default

Try this - put in a sheet module
(I assume you are editing the cell and then wanting to move 2 rows down after edit)

Code:
Private Sub Worksheet_Change(ByVal Target As Range)
    Dim myrange as range
    Set myrange = Union(Range("A3"), Range("A5"), Range("A7"))
    If Intersect(myrange, Target) Is Nothing Then Exit Sub
    Target.Offset(2, 0).Select
End Sub
Make your range specific to what you want



To apply to column A only:
Code:
Private Sub Worksheet_Change(ByVal Target As Range)
    Dim myrange as range
    Set myrange = Columns("A:A") 
    If Intersect(myrange, Target) Is Nothing Then Exit Sub
    Target.Offset(2, 0).Select
End Sub
To apply to every cell in the worksheet:
Code:
Private Sub Worksheet_Change(ByVal Target As Range)
    Target.Offset(2, 0).Select
End Sub
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
Userform calls other userform, then populate worksheet Lehoi Excel Programming 0 02-03-2016 02:58 PM
Help with UserForm Help with VBA userform benn PowerPoint 1 03-02-2015 11:32 AM
Help with UserForm Keep Userform on Top didjee PowerPoint 5 10-20-2014 02:22 PM
VBA Code in a UserForm module to delete a Command Button which opens the userform Simoninparis Word VBA 2 09-21-2014 03:50 AM
Help with UserForm Is it possible to take an input from a UserForm in one document to a UserForm in a do BoringDavid Word VBA 5 05-09-2014 09:08 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 02:57 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft