메인 컨텐츠로 가기

Excel에서 숨겨진 시트를 보호하기 위해 암호를 설정하는 방법은 무엇입니까?

중요한 숨겨진 워크 시트가 포함 된 통합 문서가 있고 다른 사람이 숨기기 해제를 허용하지 않는 경우. 이제 숨겨진 워크 시트를 완전히 보호하기 위해 암호를 설정해야합니다. 다른 사용자가 숨김을 해제 할 때 암호를 입력해야합니다. Excel에서이 작업을 빠르고 쉽게 처리 할 수있는 방법이 있습니까?

VeryHidden 기능으로 숨겨진 시트를 보호하기위한 비밀번호 설정

VBA 코드로 숨겨진 시트를 보호하기 위해 비밀번호 설정

Kutools for Excel로 한 번에 여러 워크 시트 보호


VeryHidden 기능으로 숨겨진 시트를 보호하기위한 비밀번호 설정

일반적으로 VeryHidden 기능을 사용하여 먼저 워크 시트를 숨긴 다음 암호를 설정할 수 있습니다. 다음 단계를 수행하십시오.

1. 통합 문서를 열고 Alt + F11키를 눌러 Microsoft Visual Basic for Applications 창.

2. 에서 Microsoft Visual Basic for Applications 창클릭 관측 > 프로젝트 탐색기 속성 창 to 창을 표시합니다.

문서-보호-숨겨진-시트-01

3. 그리고 프로젝트 -VBAProject 창에서 숨기려는 워크 시트를 선택하고 등록 창에서 드롭 다운 목록을 클릭합니다. 명백한 선택할 섹션 xlSheet매우숨김 옵션, 스크린 샷 참조 :

문서-보호-숨겨진-시트-02

4. 워크 시트를 매우 숨긴 후 보호하기 위해 암호를 설정할 수 있습니다. 에서 Microsoft Visual Basic for Applications 창클릭 끼워 넣다 > 모듈 빈 모듈을 열려면 도구 > VBAProject 속성, 스크린 샷 참조 :

문서-보호-숨겨진-시트-03

5. 그런 다음 튀어 나와 VBAProject- 프로젝트 속성 대화 상자에서 보호 탭을 클릭 한 다음 보기를 위해 프로젝트 잠금 상자에 마지막으로 암호를 입력하고 확인합니다. 프로젝트 속성을보기위한 암호 섹션, 스크린 샷 참조 :

문서-보호-숨겨진-시트-04

6. 그런 다음 OK 버튼을 눌러이 대화 상자를 종료하고 Microsoft Visual Basic for Applications 창.

7. 통합 문서를 다른 이름으로 저장 Excel 매크로 사용 통합 문서 암호 보호를 적용하려면 포맷하고 닫으십시오.

문서-보호-숨겨진-시트-05

8. 다음에이 통합 문서를 열고 매우 숨겨진 시트를 표시하려면 암호를 입력해야합니다. 스크린 샷보기 :

문서-보호-숨겨진-시트-06


데모 : 숨겨진 시트를 보호하기위한 비밀번호 설정


VBA 코드로 숨겨진 시트를 보호하기 위해 비밀번호 설정

숨겨진 시트를 보호하기 위해 암호를 설정하기 위해 VBA 코드에 대해 이야기 할 수도 있습니다.

1. 보호 할 워크 시트 하나를 숨 깁니다.

2. 누르고 ALT + F11 키를 눌러 Microsoft Visual Basic for Applications 창.

3. 그런 다음 이 워크북 왼쪽에서 프로젝트 탐색기, 두 번 클릭하여 모듈를 클릭 한 다음 다음 VBA 코드를 복사하여 빈 모듈에 붙여 넣습니다.

VBA 코드 : 숨겨진 시트를 보호하기위한 비밀번호 설정

Private Sub Workbook_SheetActivate(ByVal Sh As Object)
Dim xSheetName As String
xSheetName = "Sheet1"
If Application.ActiveSheet.Name = xSheetName Then
    Application.EnableEvents = False
    Application.ActiveSheet.Visible = False
    xTitleId = "KutoolsforExcel"
    response = Application.InputBox("Password", xTitleId, "", Type:=2)
    If response = "123456" Then
        Application.Sheets(xSheetName).Visible = True
        Application.Sheets(xSheetName).Select
    End If
End If
Application.Sheets(xSheetName).Visible = True
Application.EnableEvents = True
End Sub

문서-보호-숨겨진-시트-07

주의 사항: 위 코드에서 Sheet1 xSheetName = "시트 1" script는 보호하려는 숨겨진 워크 시트 이름입니다. 123456 FBI 증오 범죄 보고서 응답 = "123456"이면 script는 숨겨진 시트에 대해 설정 한 비밀번호입니다. 필요에 따라 변경할 수 있습니다.

4. 이제 숨겨진 시트를 표시하고 싶을 때 암호를 입력 할 수있는 프롬프트 상자가 나타납니다. 이 프롬프트 상자는 숨겨진 시트를 표시하기 위해 클릭 할 때마다 나타납니다.

문서-보호-숨겨진-시트-08


Kutools for Excel로 한 번에 여러 워크 시트 보호

통합 문서의 여러 선택 또는 모든 워크 시트를 한 번에 보호하려면 일반적으로 Excel에서 수동으로 하나씩 보호해야합니다. 그러나 만약 당신이 Excel 용 Kutools그와 워크 시트 보호 유틸리티를 사용하면 한 번의 클릭으로 보호 할 수 있습니다.

Excel 용 Kutools : 300 개 이상의 편리한 Excel 추가 기능으로 30 일 동안 제한없이 무료로 사용해 볼 수 있습니다.

설치 후 Excel 용 Kutools, 다음과 같이하십시오.

1. 딸깍 하는 소리 쿠툴즈 플러스 > 워크 시트 보호, 스크린 샷 참조 :

2. 에서 워크 시트 보호 대화 상자에서 통합 문서 내의 모든 워크 시트가 목록 상자에 나열됩니다. 보호 할 워크 시트를 선택하십시오. 스크린 샷보기 :

문서-보호-숨겨진-시트-010

3. 그런 다음 OK, 다음 대화 상자에서 암호를 입력하고 다시 입력 한 다음 OK, 보호 된 워크 시트 수를 알려주는 또 다른 프롬프트 상자가 나타납니다.

문서-보호-숨겨진-시트-011

4. 그런 다음 OK 대화 상자를 닫고 통합 문서의 모든 워크 시트가 동일한 암호로 보호되었습니다.

참고 : 한 번에 모든 워크 시트의 보호를 해제하려면 쿠툴즈 플러스 > 워크 시트 보호 해제을 클릭하고 암호를 입력하여 보호를 취소하십시오.

 Excel 용 Kutools를 지금 다운로드하고 무료로 평가하십시오!


관련 기사 :

Excel에서 한 번에 여러 워크 시트를 보호하는 방법은 무엇입니까?

통합 문서를 보호하기 위해 암호를 설정하는 방법은 무엇입니까?

Excel에서 VBA 코드를 보호 / 잠그는 방법은 무엇입니까?

최고의 사무 생산성 도구

🤖 Kutools AI 보좌관: 다음을 기반으로 데이터 분석을 혁신합니다. 지능형 실행   |  코드 생성  |  사용자 정의 수식 만들기  |  데이터 분석 및 차트 생성  |  Kutools 기능 호출...
인기 기능: 중복 항목 찾기, 강조 표시 또는 식별   |  빈 행 삭제   |  데이터 손실 없이 열이나 셀 결합   |   수식없이 반올림 ...
슈퍼 조회: 다중 기준 VLookup    다중 값 VLookup  |   여러 시트에 걸친 VLookup   |   퍼지 조회 ....
고급 드롭다운 목록: 드롭다운 목록을 빠르게 생성   |  종속 드롭다운 목록   |  다중 선택 드롭 다운 목록 ....
열 관리자: 특정 개수의 열 추가  |  열 이동  |  Toggle 숨겨진 열의 가시성 상태  |  범위 및 열 비교 ...
특색 지어진 특징: 그리드 포커스   |  디자인보기   |   큰 수식 바    통합 문서 및 시트 관리자   |  리소스 라이브러리 (자동 텍스트)   |  날짜 선택기   |  워크 시트 결합   |  셀 암호화/해독    목록으로 이메일 보내기   |  슈퍼 필터   |   특수 필터 (굵게/기울임꼴/취소선 필터링...) ...
상위 15개 도구 세트12 본문 도구 (텍스트 추가, 문자 제거,...)   |   50+ 거래차트 유형 (Gantt 차트,...)   |   40+ 실용 방식 (생일을 기준으로 나이 계산,...)   |   19 삽입 도구 (QR 코드 삽입, 경로에서 그림 삽입,...)   |   12 매출 상승 도구 (숫자를 단어로, 환율,...)   |   7 병합 및 분할 도구 (고급 결합 행, 셀 분할,...)   |   ... 그리고 더

Excel용 Kutools로 Excel 기술을 강화하고 이전과는 전혀 다른 효율성을 경험해 보세요. Excel용 Kutools는 생산성을 높이고 시간을 절약하기 위해 300개 이상의 고급 기능을 제공합니다.  가장 필요한 기능을 얻으려면 여기를 클릭하십시오...

상품 설명


Office Tab은 Office에 탭 인터페이스를 제공하여 작업을 훨씬 쉽게 만듭니다.

  • Word, Excel, PowerPoint에서 탭 편집 및 읽기 사용, Publisher, Access, Visio 및 Project.
  • 새 창이 아닌 동일한 창의 새 탭에서 여러 문서를 열고 만듭니다.
  • 생산성을 50% 높이고 매일 수백 번의 마우스 클릭을 줄입니다!
Comments (10)
No ratings yet. Be the first to rate!
This comment was minimized by the moderator on the site
jak ktoś ukrył arkusz jak w opisanym pierwszym sposobie, a nie znamy hasła to jak odkryć arkusz skoro hasło do visual basic jest w ukrytym arkuszu?
This comment was minimized by the moderator on the site
Hello, ciekawa

Sorry, at present, there is no good way for canceling the protect of the hidden sheet if you forget the password.

But, you can apply the Uhide all hidden sheets feature of Kutools for Excel to unhide all the hidden sheets without any password.
https://www.extendoffice.com/images/stories/comments/comment-skyyang/doc-unhide-sheets.png
You can download Kutools for Excel and use it freely for 30 days.
Please have a try. Thank you!
This comment was minimized by the moderator on the site
This is elegant. IF the person opening the spreadsheet does not enable macros (i.e. VBA) what happens? Is the hidden sheet a sitting duck? Or is it quite impossible to find?
This comment was minimized by the moderator on the site
Hi, David,
If you open the workbook without enabling the macro, the hidden sheet is displayed as normal. In this case, I recommend you to apply the first method for solving this job.
Thank you!
This comment was minimized by the moderator on the site
Your code allows users to view the sheet as long as they hold the left mouse button while the mouse pointer is on the tab. Try this to keep sheet hidden until correct password is entered: If response = "123456" Then Application.Sheets(xSheetName).Visible = True Application.Sheets(xSheetName).Select Else Application.Sheets(xSheetName).Visible = False[/b][/b] End If End If Application.EnableEvents = True End Sub
This comment was minimized by the moderator on the site
I have a question about your password restricted worksheet code. You posted the following code which works....what I am looking for is code that will do this with multiple worksheets and multiple passwords within the same workbook. Is this possible? Private Sub Workbook_SheetActivate(ByVal Sh As Object) 'Update 20140925 Dim xSheetName As String xSheetName = "sheet1" If Application.ActiveSheet.Name = xSheetName Then Application.EnableEvents = False Application.ActiveSheet.Visible = False xTitleId = "KutoolsforExcel" response = Application.InputBox("Password", xTitleId, "", Type:=2) If response = "123456" Then Application.Sheets(xSheetName).Visible = True Application.Sheets(xSheetName).Select End If End If Application.Sheets(xSheetName).Visible = True Application.EnableEvents = True End Sub
This comment was minimized by the moderator on the site
Found a solution yet?

I am having the same problem
This comment was minimized by the moderator on the site
Private Sub Workbook_SheetActivate(ByVal Sh As Object)
Dim aSheetName As String
Dim bSheetName As String
Dim cSheetName As String
aSheetName = "sheet1"
bSheetName = "sheet2"
cSheetName = "sheet3"

If Application.ActiveSheet.Name = aSheetName Then
Application.EnableEvents = False
Application.ActiveSheet.Visible = False
xTitleId = "KutoolsforExcel"
response = Application.InputBox("Password", xTitleId, "", Type:=2)
If response = "123" Then
Application.Sheets(aSheetName).Visible = True
Application.Sheets(aSheetName).Select
Else
Application.Sheets(aSheetName).Visible = False
End If
End If
Application.EnableEvents = True

If Application.ActiveSheet.Name = bSheetName Then
Application.EnableEvents = False
Application.ActiveSheet.Visible = False
xTitleId = "KutoolsforExcel"
response = Application.InputBox("Password", xTitleId, "", Type:=2)
If response = "456" Then
Application.Sheets(bSheetName).Visible = True
Application.Sheets(bSheetName).Select
Else
Application.Sheets(bSheetName).Visible = False
End If
End If
Application.EnableEvents = True

If Application.ActiveSheet.Name = cSheetName Then
Application.EnableEvents = False
Application.ActiveSheet.Visible = False
xTitleId = "KutoolsforExcel"
response = Application.InputBox("Password", xTitleId, "", Type:=2)
If response = "789" Then
Application.Sheets(cSheetName).Visible = True
Application.Sheets(cSheetName).Select
Else
Application.Sheets(cSheetName).Visible = False
End If
End If
Application.EnableEvents = True

End Sub
This comment was minimized by the moderator on the site
Thanks for the code, just have one question. When you open the sheet you are asked for question, then you enter it and the sheet is visible, but when you jump to next sheet and try to re-open previous sheet, you are asked for the same password again everytime. My question is can you bypass that and make excel ask for password once?
This comment was minimized by the moderator on the site
Private Sub Workbook_SheetActivate(ByVal Sh As Object)
Dim xSheetName As String
aSheetName = "sheet1"
bSheetName = "sheet2"
cSheetName = "sheet3"

If Application.ActiveSheet.Name = aSheetName Then
Application.EnableEvents = False
Application.ActiveSheet.Visible = False
xTitleId = "KutoolsforExcel"
response = Application.InputBox("Password", xTitleId, "", Type:=2)
If response = "1234" Then
Application.Sheets(aSheetName).Visible = True
Application.Sheets(aSheetName).Select
Else
Application.Sheets(aSheetName).Visible = False
End If
End If
Application.EnableEvents = True

If Application.ActiveSheet.Name = bSheetName Then
Application.EnableEvents = False
Application.ActiveSheet.Visible = False
xTitleId = "KutoolsforExcel"
response = Application.InputBox("Password", xTitleId, "", Type:=2)
If response = "2345" Then
Application.Sheets(bSheetName).Visible = True
Application.Sheets(bSheetName).Select
Else
Application.Sheets(bSheetName).Visible = False
End If
End If
Application.EnableEvents = True

If Application.ActiveSheet.Name = cSheetName Then
Application.EnableEvents = False
Application.ActiveSheet.Visible = False
xTitleId = "KutoolsforExcel"
response = Application.InputBox("Password", xTitleId, "", Type:=2)
If response = "3456" Then
Application.Sheets(cSheetName).Visible = True
Application.Sheets(cSheetName).Select
Else
Application.Sheets(cSheetName).Visible = False
End If
End If
Application.EnableEvents = True

End Sub
There are no comments posted here yet
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations