excel macro lock and protect sheet code example Example: excel vba protect worksheet without password Worksheets("Sheet1").Unprotect "Password"