Model opens up with hidden rows and columns

G

Guest

I have a model which is getting quite large. At one point I was manually (no
VBA code) hiding rows and columns of a particular sheet for esthetics.
However when I open the model, everything in this particular sheet is now
hidden. So I highlight everything and unhide and save. But I have to do
this every do often. Its almost as though Excel is keeping something in
residual memory which is causing the the sheet to hide everything in this
sheet every so often. Unhiding and saving only seems to work for a while.
The next day I come in, open up and all is hidden again. Can anybody tell
why this his happening? The only fix I can think of is to have a routine
which unhides everything in the sheet upon the open event. But this is silly.

Thanks

EM
 
G

Guest

This seems to have after I pull up custom views on other sheets. Could it be
that I have to uhide the rows/columns and then reset every custom view and
then save?

EM
 
G

Guest

This does not work either. I unhide, pick a customer view, then go back to
the sheet, as expected, everything is hidden again, I unhide, redefine the
print view and save. But it eventualy hides it again. Wondering if I need
to reset all customer views from scratch.

EM
 
G

Guest

A custom view has a workbook perspective as I recall - not just for the sheet
that was active when it was applied. So you probably do have to redefine
your views.
 
G

Guest

So Tom, I just went through and redefined every custom view I have making
sure that the sheet in question had all its rows/columns unhidden while I was
redefining the views. I then saved the file. Now when I chose any of my
redefined custom views, and go back to the sheet in question, everything is
hidden. What a joke. I can't believe this. This completely renders the
spreadsheet useless as users will not know what is going on. I need the
views too.

I can always try to replace the views with print macros - but I shouldn't
need to do this.

EM
 
G

Guest

All I can do is put this intot the Worksheet_Activate Event:

Private Sub Worksheet_Activate()
Cells.Select
Selection.EntireRow.Hidden = False
Selection.EntireColumn.Hidden = False
End Sub

EM
 
G

Guest

Make a copy of your workbook

open the copy

delete all custom views.

Now make sure all the rows are unhidden.

Save the workbook.

close it.

Open it. If the rows are unhidden, then recreate your custom views making
sure you never hide the rows. Create them one at a time, saving and
closing after creating. When you open, make sure you haven't recreated the
problem.
 
G

Guest

So, I delted all the views. I then created them from scratch. When you
create the view it provides two check boxes. One for Print Settings and the
other for Hidden Rows/Columns. I uncheck the hidden rows/columns. I did
this for all the views. This seemed to make a difference. Not sure why as I
am assuming the check box is supposed to refer to the sheet the view is on.
Whereas my problem was that if I chose a certain view it then hid rows on a
different sheet altogether.

So now I write a macro which chooses the viewsa and then prints them. For
example:

ActiveWorkbook.CustomViews("Legend&Dates&Finance&Indexation").Show
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True

However I am noticing that certain vews are not printing up the way they are
supposed to. I have noticed that I have to actually select the view twice to
make look the way its supposed to. As such, I have write the code like this
to duplicate the selection actions:

ActiveWorkbook.CustomViews("Legend&Dates&Finance&Indexation").Show
ActiveWorkbook.CustomViews("Legend&Dates&Finance&Indexation").Show
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True

I think this is bizarre. Also I am not convinced yet that even if I fix
this that it will work consistently on another computer/printer.

EM
 

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