Hi. i want to hide and lock formula inside a macro worksheet. but after changing the format, the worksheet is lock and cannot use it unless unlocked.
this is the macro
Sub copydata()
Dim lc As Integer
lc = Sheets("Sheet1 (2)").Cells(6, Columns.Count).End(xlToLeft).Column + 1
Sheets("Sheet1").Range("D4:D21").Copy Sheets("Sheet1 (2)").Cells(4, lc)
Sheets("Sheet1").Range("D6:D21").ClearContents
Sheets("Sheet1").Range("D4").ClearContents
End Sub
i have added 2 columns inside sheet1 that uses max and min functions, its this formula i want to hide and lock to prevent from correction or accidentally deleted by user.
which line i have to modify? and how?
totally clueless with macro. i get help by sktneer before
thanks.
by the way, can we lock the sheet name so that it can't be change by the user?
thanks again.
Bookmarks