Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,670
Default Macro for Menu at start up

Hello all,

When I start a program I want the auto calculation to automaticly come on.
I also want to ensure that when the program is open that no one can get to
the macros. When the program is closed I want it to auto save and for
anyother program that opens to open with a "normal" menu bar. I hope this
makes sense.......Thank you in advance for all your help.

Eric
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 130
Default Macro for Menu at start up

Eric,

Here is some code for the autocalculation and saving.

By your words; "no one can get to the macros." Are you trying to block them
from the project or from running a macro period?

'Put this in a Auto_Open sub
With Application
.Calculation = xlAutomatic
End With

'Do this to keep people from your code
Go to Tools VBAProject properties, lock the project for viewing, and enter
a password.

'Put this in a auto_Close sub
ActiveWorkbook.Save


"Eric" wrote:

Hello all,

When I start a program I want the auto calculation to automaticly come on.
I also want to ensure that when the program is open that no one can get to
the macros. When the program is closed I want it to auto save and for
anyother program that opens to open with a "normal" menu bar. I hope this
makes sense.......Thank you in advance for all your help.

Eric

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,670
Default Macro for Menu at start up

this is good but how do I get this macro to activate automaticly when I open
this book?
Also, you told me about the auto_close sub How do I get that to work
automaticly?

As you can see this is new territory for me.......

Eric

"JRForm" wrote:

Eric,

Here is some code for the autocalculation and saving.

By your words; "no one can get to the macros." Are you trying to block them
from the project or from running a macro period?

'Put this in a Auto_Open sub
With Application
.Calculation = xlAutomatic
End With

'Do this to keep people from your code
Go to Tools VBAProject properties, lock the project for viewing, and enter
a password.

'Put this in a auto_Close sub
ActiveWorkbook.Save


"Eric" wrote:

Hello all,

When I start a program I want the auto calculation to automaticly come on.
I also want to ensure that when the program is open that no one can get to
the macros. When the program is closed I want it to auto save and for
anyother program that opens to open with a "normal" menu bar. I hope this
makes sense.......Thank you in advance for all your help.

Eric

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 130
Default Macro for Menu at start up

Eric,

Open the code window and look in the project pane for "This Workbook" and
select it.
Post this in the code module. Once your code is in place then close and
open the file

Private Sub Workbook_BeforeClose(Cancel As Boolean)
'place code in here to execute the code at close of spreadsheet

End Sub


Private Sub Workbook_Open()
'Place code in here if you want it run when the file is opened

End Sub

"Eric" wrote:

this is good but how do I get this macro to activate automaticly when I open
this book?
Also, you told me about the auto_close sub How do I get that to work
automaticly?

As you can see this is new territory for me.......

Eric

"JRForm" wrote:

Eric,

Here is some code for the autocalculation and saving.

By your words; "no one can get to the macros." Are you trying to block them
from the project or from running a macro period?

'Put this in a Auto_Open sub
With Application
.Calculation = xlAutomatic
End With

'Do this to keep people from your code
Go to Tools VBAProject properties, lock the project for viewing, and enter
a password.

'Put this in a auto_Close sub
ActiveWorkbook.Save


"Eric" wrote:

Hello all,

When I start a program I want the auto calculation to automaticly come on.
I also want to ensure that when the program is open that no one can get to
the macros. When the program is closed I want it to auto save and for
anyother program that opens to open with a "normal" menu bar. I hope this
makes sense.......Thank you in advance for all your help.

Eric

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Easy menu start Tesons Excel Discussion (Misc queries) 0 May 28th 08 04:08 AM
Lost Start up menu icon Carpo Excel Discussion (Misc queries) 0 April 22nd 08 04:34 PM
Add item to Start Menu joeeng Excel Programming 2 May 24th 07 07:14 PM
Opening a file without the macro start menu Fernandoalberte Excel Programming 5 June 30th 05 10:21 AM
Start Excel from send menu Jon Peltier[_7_] Excel Programming 2 July 6th 04 08:38 PM


All times are GMT +1. The time now is 04:47 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"