filmov
tv
Add new row in excel with activeX command button, code included
Показать описание
Tutorial of how to insert new row in Excel with a command button.
Code for VBA is under. Make sure you change it!
Kuidas lisada uut rida Excelis
Dim mySheets
Dim i As Long
mySheets = Array("Sheet1")
For i = LBound(mySheets) To UBound(mySheets)
With Sheets(mySheets(i))
.Range("E5").EntireRow.Insert Shift:=xlDown
.Range("E5:H5").Borders.Weight = xlThin
End With
Next i
Code for VBA is under. Make sure you change it!
Kuidas lisada uut rida Excelis
Dim mySheets
Dim i As Long
mySheets = Array("Sheet1")
For i = LBound(mySheets) To UBound(mySheets)
With Sheets(mySheets(i))
.Range("E5").EntireRow.Insert Shift:=xlDown
.Range("E5:H5").Borders.Weight = xlThin
End With
Next i