Hello,
I have the code below which I would like to add to:
Sub New_Risk()
Dim varUserInput As Variant
varUserInput = InputBox("Enter Row Number where you want to add a row:", _
"What Row?")
If varUserInput = "" Then Exit Sub
RowNum = varUserInput
ActiveSheet.Unprotect "test"
With ActiveCell
Rows(RowNum & ":" & RowNum).Insert Shift:=xlDown
Rows(RowNum - 1 & ":" & RowNum - 1).Copy Range("A" & RowNum)
Range(RowNum & ":" & RowNum).SpecialCells(xlCellTypeConstants).ClearContents
End With
Application.CutCopyMode = False
ActiveSheet.Protect "test"
End Sub
I would like to allow the user to format row and columns (height and widths) and apply filters but not sure how to add this in.
Can anyone assist?
I have the code below which I would like to add to:
Sub New_Risk()
Dim varUserInput As Variant
varUserInput = InputBox("Enter Row Number where you want to add a row:", _
"What Row?")
If varUserInput = "" Then Exit Sub
RowNum = varUserInput
ActiveSheet.Unprotect "test"
With ActiveCell
Rows(RowNum & ":" & RowNum).Insert Shift:=xlDown
Rows(RowNum - 1 & ":" & RowNum - 1).Copy Range("A" & RowNum)
Range(RowNum & ":" & RowNum).SpecialCells(xlCellTypeConstants).ClearContents
End With
Application.CutCopyMode = False
ActiveSheet.Protect "test"
End Sub
I would like to allow the user to format row and columns (height and widths) and apply filters but not sure how to add this in.
Can anyone assist?