locked worksheet

J

Joan

I have locked my worksheet and saved it . When I go to open it, I cannot get
a whole window displayed. I have tried the icons for whole, half, etc. in
the lower right hand corner.
 
J

Jan Karel Pieterse

Hi Joan,
When I go to open it, I cannot get
a whole window displayed. I have tried the icons for whole, half, etc. in
the lower right hand corner.

You need to unprotect the workbook and maximize its window. Then protect it
again.

Regards,

Jan Karel Pieterse
Excel MVP
http://www.jkp-ads.com
Member of:
Professional Office Developer Association
www.proofficedev.com
 
J

Joan

Thanks for replying. Just tried that and it made no difference. Anhy other
suggestions? I know it can work because somehow my first locked spreadsheet
does not have this problem, but I cannot figure out what is different,
besides the size of the file.
 
J

Jan Karel Pieterse

Hi Joan,
I know it can work because somehow my first locked spreadsheet
does not have this problem, but I cannot figure out what is different,
besides the size of the file.

Could you explain a little bit more what happens when you open your file, e.g.:

Is the window of the file the wrong size?
Are you not able to see the entire document window?
What happens if you select (from the view menu) Arrange all, horizontal (or any
other option)?

Regards,

Jan Karel Pieterse
Excel MVP
http://www.jkp-ads.com
Member of:
Professional Office Developer Association
www.proofficedev.com
 
J

Joan

Spreadsheet is 120 columns x 5000 rows. Headings and first two columns are
set to always show. Client needs access only to the body of the spreadsheet.

In full window I protect Sheet then Structure and Windows. Save and close.
When I open the file to verify that it is locked, the spreadsheet only takes
up the right half of the screen. The left side of the screen is empty.
Because it is locked, I cannot expand the window. I cannot drag the window
nor move it view it or reduce or enlarge it. I need to protect the window so
that the client must always have the headings and first two colums. If I only
protect the structure and not the window, then I do not have this issue.
 
J

Jan Karel Pieterse

Hi Joan,
Spreadsheet is 120 columns x 5000 rows. Headings and first two columns are
set to always show. Client needs access only to the body of the spreadsheet.

So you are protecting the windows just to prevent the user from changing the
freeze panes option, right?

I see three solutions:

1. Don't protect windows, if the user decides he wants to unfreeze panes, let
him do so

2. Unprotect the workbook, set window to normal size, resize the window as big
as fits in your (and the clients!!) screen, reprotect the workbook

3. Use VBA code that maximizes the window when the book opens:

In the Thisworkbook module of your file:

Option Explicit

Private Sub Workbook_Open()
Me.Unprotect "PassWord"
ActiveWindow.WindowState = xlMaximized
Me.Protect "PassWord", True, True
End Sub

Regards,

Jan Karel Pieterse
Excel MVP
http://www.jkp-ads.com
Member of:
Professional Office Developer Association
www.proofficedev.com
 
J

Joan

Thank you for replying back. I already went with solution no. 1. I had to
upload the file for users. This is what I would call a work-around. What is
VBA code and how can I learn it?
 
J

Jan Karel Pieterse

Hi Joan,
What is VBA code and how can I learn it?

VBA code is the macro language of Office.

You start learning by recording a macro and looking at the recorded code. Next
step is to get yourself a book on VBA (the Dummies book is a good starting
point IMO).

There are tons of sites showing examples of VBA code. Google is your friend!

Regards,

Jan Karel Pieterse
Excel MVP
http://www.jkp-ads.com
Member of:
Professional Office Developer Association
www.proofficedev.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top