Macros write a macro from sheet 1 to copy data when selected
Closed
ruincontrl
Posts
1
Registration date
Tuesday 7 February 2017
Status
Member
Last seen
7 February 2017
-
7 Feb 2017 à 14:32
vcoolio Posts 1411 Registration date Thursday 24 July 2014 Status Contributor Last seen 6 September 2024 - 9 Feb 2017 à 04:42
vcoolio Posts 1411 Registration date Thursday 24 July 2014 Status Contributor Last seen 6 September 2024 - 9 Feb 2017 à 04:42
Related:
- Macros write a macro from sheet 1 to copy data when selected
- How to copy data from one excel sheet to another - Guide
- How to write ' on keyboard - Guide
- Tentacle locker 1 - Download - Adult games
- Igi 1 - Download - Shooters
- Excel online macros - Guide
1 response
vcoolio
Posts
1411
Registration date
Thursday 24 July 2014
Status
Contributor
Last seen
6 September 2024
262
9 Feb 2017 à 04:42
9 Feb 2017 à 04:42
Hello Ruincontrl,
Try the following code in a standard module assigned to a button:-
Select the row of data that you wish to transfer to Sheet2 then click on the button and that row will be transferred to Sheet2 and deleted from Sheet1.
I hope that this helps.
Cheerio,
vcoolio.
Try the following code in a standard module assigned to a button:-
Sub TransferData()
Dim Confirm As String
Confirm = MsgBox("The selected row will be copied to Sheet2 and deleted from Sheet1.", vbOKCancel, "Copy Entire Row")
If Confirm = vbCancel Then Exit Sub
Selection.Copy Sheet2.Range("A" & Rows.Count).End(xlUp).Offset(1, 0)
Selection.EntireRow.Delete
MsgBox "Data transfer complete!", vbExclamation
Sheet2.Select
End Sub
Select the row of data that you wish to transfer to Sheet2 then click on the button and that row will be transferred to Sheet2 and deleted from Sheet1.
I hope that this helps.
Cheerio,
vcoolio.