force first page view

  • Thread starter Thread starter amanda
  • Start date Start date
A

amanda

Hi,

I have an excel spreadsheet with lots of different sheets. I want the force
a specific sheet to be visible whenever the file is opened - irrelevant of
how the file was saved. So, the specific sheet is the first thing that
anyone who opens the file sees.

Is that possible?

Thank you

Amanda
 
Amanda,

Alt+F11 to open VB editor. Double click 'ThisWorkbook' and paste the code
below in.

Change the name to the sheet you want


Private Sub Workbook_Open()
Application.Goto Sheets("Particular sheet").Range("A1")
End Sub
--
Mike

When competing hypotheses are otherwise equal, adopt the hypothesis that
introduces the fewest assumptions while still sufficiently answering the
question.
 
Hi Mike,

I have done that, but if I save on any sheet other than the one named it
does work. Have I done something wrong?

Thanks

Amanda
 
I should have said 'does not work' in my post, only if I save the file on
that sheet does it open with it showing.
 
Amanda,

You must follow the installation instructions precisely.

Alt+F11 to open VB editor
Double click 'ThisWorkbook'
Paste the code in on the right
Change this line

Application.Goto Sheets("Particular sheet").Range("A1")

To the name of your required sheet. For example

Application.Goto Sheets("MySheet").Range("A1")

Now save and close Excel and re-open ensuring macros are enabled and the
code will select A1 of the named sheet.
--
Mike

When competing hypotheses are otherwise equal, adopt the hypothesis that
introduces the fewest assumptions while still sufficiently answering the
question.
 
Hi,

It does work, thank you. It is my macro security options that isn't let it
wrong. I did not notice the message the first time.

Is there anyway I can have this particular macro run all the time without
the need to unblock all macros?

Thanks

Amanda
 
You could reduce the macro security level. See Excel help on how to do that
--
Mike

When competing hypotheses are otherwise equal, adopt the hypothesis that
introduces the fewest assumptions while still sufficiently answering the
question.
 
Back
Top