Hi All,
I am stuck on something and I am hoping that someone can help me out.
I want to be able to select the cell where this macro will start. IE: Change the Range("C1").select to a user select by clicking a cell? I am not sure how to go about it. What this macro does is it selects a range of columns and rows starting in column C and cuts and pastes it to that last open row in Column A. Its a simple program.
In the columns I have a item number and units. So Lets say I have 8 columns with 10 rows. I cut columns C:H to row 10. Then paste it in A11. Repeat. So I would click C11, Cut (Columns & Rows) paste in A21. Repeat. Unitl I have all 4 segments (Item # & Units) in the same two columns. Any suggestions on how I can manually click the starting point? Thanks so much in advance!!!
Sub Move_Columns()
'
' Move_Columns Macro
'
Range("C1").Select
Range(Selection, Selection.End(xlToRight)).Select
Range(Selection, Selection.End(xlDown)).Select
Application.CutCopyMode = False
Selection.Cut
'Last Row FORMULA
Dim LastRowBrand As Long
With ActiveSheet
LastRowBrand = .Range("B1").SpecialCells(xlCellTypeLastCell).Row
End With
Range("A" & LastRowBrand).Select
ActiveSheet.Paste
End Sub
I am stuck on something and I am hoping that someone can help me out.
I want to be able to select the cell where this macro will start. IE: Change the Range("C1").select to a user select by clicking a cell? I am not sure how to go about it. What this macro does is it selects a range of columns and rows starting in column C and cuts and pastes it to that last open row in Column A. Its a simple program.
In the columns I have a item number and units. So Lets say I have 8 columns with 10 rows. I cut columns C:H to row 10. Then paste it in A11. Repeat. So I would click C11, Cut (Columns & Rows) paste in A21. Repeat. Unitl I have all 4 segments (Item # & Units) in the same two columns. Any suggestions on how I can manually click the starting point? Thanks so much in advance!!!
Sub Move_Columns()
'
' Move_Columns Macro
'
Range("C1").Select
Range(Selection, Selection.End(xlToRight)).Select
Range(Selection, Selection.End(xlDown)).Select
Application.CutCopyMode = False
Selection.Cut
'Last Row FORMULA
Dim LastRowBrand As Long
With ActiveSheet
LastRowBrand = .Range("B1").SpecialCells(xlCellTypeLastCell).Row
End With
Range("A" & LastRowBrand).Select
ActiveSheet.Paste
End Sub