Excel VBA memindahkan bentuk ke baris terakhir
Sub MoveButton()
Dim ws As Worksheet
Dim lr As Long
Dim buttonCell As Range
Dim shp As Shape
Set ws = Sheets("Sheet1") 'Sheet where shape is inserted
lr = ws.Cells(Rows.Count, 1).End(xlUp).Row + 1 'first empty row in column A
Set buttonCell = ws.Cells(lr, "A") 'setting the cell where button will be placed
Set shp = ws.Shapes("myShape") 'name of the shape is "myShape", change it as per your requirement
'set the shape dimensions
With shp
.Left = buttonCell.Left
.Top = buttonCell.Top
End With
End Sub
Nutty Narwhal