Hi friends,
My friend had given me a problem in excel of copy row whenever the values changed to another sheet next available row.
I have come-up with this following code
Private Sub Worksheet_Change(ByVal Target As Range)
If Not Application.Intersect(Target, Target.ActiveSheet.Range("A1:D1")) Is Nothing Then
Application.EnableEvents = False
Application.ScreenUpdating = False
MsgBox ("Hi")
Call ValueChange
Application.EnableEvents = True
End If
End Sub
Sub ValueChange()
Dim lastrow As Long
lastrow = Sheets("Sheet2").Range("A65536").End(xlUp).Row + 1
Sheets("Sheet2").Range("A" & lastrow & ": D" & lastrow).Value = Sheets("Sheet1").Range("A1:D1").Value
End Sub
Hope it will help you.
Note:
Please share your valuable comments and feedback to psrdotcom@gmail.com
Subscribe to:
Posts (Atom)
Featured Post
Java Introdcution
Please send your review and feedback to psrdotcom@gmail.com
-
Hi all, Today, I'll explain how to uninstall completely the openjdk from the RedHat Enterprise Linux (RHEL) machine. Some of the sof...
-
Hi folks, Today we are going to see, how we can run or deploy the Go (Golang) project in IIS. Development Create your Golang project with w...
-
Hi friends, I have updated my Aadhaar details from Aadhaar update center. It is mentioned that within 72 hours, my details will be update...