Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9118899
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T05:15:55+00:00 2026-06-17T05:15:55+00:00

I have a workbook in which i have several sheets according to requirement. In

  • 0

I have a workbook in which i have several sheets according to requirement. In this workbook i have used macros and to lock some particular cells and columns i have used unprotect and protect options. Everything works fine on my machine but when i make it as SharedWorkBook it is giving me errors particularly the ThisWorkBook.Sheets(“PSE”).Unprotect and ThisWorkBook.Sheets(“PSE”).Protect statements. So in place of them i used ThisWorkBook.Sheets(“PSE”).UnprotectSharing and ThisWorkBook.Sheets(“PSE”).ProtectSharing . Even now also i am getting errors with those lines.


Sub SheetHider()
ThisWorkbook.Sheets("SheetA").UnprotectSharing
Cuser = ThisWorkbook.Sheets("SheetA").Range("A2").Value

and the error is
Runtime error ‘438’ Object doesn’t support this property or method.

My Requirement: 1)I have to use Macros, Locking property so that i have to use Unprotect and Protect statements and these things should work when i make it as SharedWorkBook.
I have been searching many sites for this for a week. Atleast give me some alternatives to do this.
Any help will be appreciated greatly. Thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T05:15:56+00:00Added an answer on June 17, 2026 at 5:15 am

    UnprotectSharing and ProtectSharing both belong to the Workbook object. So you can’t do what you are trying to do.

    You can do ThisWorkbook.UnprotectSharing and ThisWorkbook.ProtectSharing but that is only design to protect the Shared Workbook setting so that people can’t remove it without a password.

    Secondly you can’t unprotect or protect sheets when a workbook is shared. You would have to unshare the workbook, unprotect the sheet and then share the workbook again. Which isn’t very practicable.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an Excel Workbook which has some VSTO-based c# code. Given a known
I have a WorkBook and I'm trying to delete sheets which names don't match
I have a workbook,which contains ActiveX control button and form control button and macros
I have a workbook which has a macro that copies some data into a
So I have this Excel workbook which basically is supposed to be a data
I have several sparsely populated tables in an Excel workbook from which I need
I have several columns of dates, which I have distilled down into one master
I have an excel workbook which needs to query data from an HTTP server.
Lets say that I have one component which is doing something with Workbook object
I have some existing custom Excel workbooks/applications with code-behind C#, which work fine. They

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.