Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
Ed Ed is offline
external usenet poster
 
Posts: 279
Default I want the macros to be locked up when cells are locked up.

On my spreadsheet I check "Lock" for all cells. Then turn on the
"Protection" for the sheet. In this condition, no one can enter or change
any information in any of the cells. Also you cannot right click a Macro
control button and edit the Macro. This is great.

However, my Macro controls the operation of the spreadsheet.
When you click start, the operation begins and repeats the operation over
and over again continuously without stopping until you press "ESC". When you
press "ESC", the operation stops, as it should. Now in this stopped
condition, a window appears on the screen which (amoung other buttons)
contains the button "Debug".
Even when the Protection is on, you can click this button and it gives you
access to the Macro contents. You can change anything you want to, it is not
Protected.
Is there a way to Protect the contents of the Macro by preventing any access
when you click the "Debug" button?

I would appreciate any help you can give.
Thankyou
Ed
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default I want the macros to be locked up when cells are locked up.

Hi Ed

You can protect your VBA code in the VBA editior
Alt-F11
ToolsVBAproject properties


--
Regards Ron de Bruin
http://www.rondebruin.nl



"Ed" wrote in message ...
On my spreadsheet I check "Lock" for all cells. Then turn on the
"Protection" for the sheet. In this condition, no one can enter or change
any information in any of the cells. Also you cannot right click a Macro
control button and edit the Macro. This is great.

However, my Macro controls the operation of the spreadsheet.
When you click start, the operation begins and repeats the operation over
and over again continuously without stopping until you press "ESC". When you
press "ESC", the operation stops, as it should. Now in this stopped
condition, a window appears on the screen which (amoung other buttons)
contains the button "Debug".
Even when the Protection is on, you can click this button and it gives you
access to the Macro contents. You can change anything you want to, it is not
Protected.
Is there a way to Protect the contents of the Macro by preventing any access
when you click the "Debug" button?

I would appreciate any help you can give.
Thankyou
Ed



  #3   Report Post  
Posted to microsoft.public.excel.programming
Ed Ed is offline
external usenet poster
 
Posts: 279
Default I want the macros to be locked up when cells are locked up.

Hi Ron
Thanks for the response.
I looked at the "Tools VBAproject Properties" and am unable to figure out
what the coding would be.
Could you give me sample entries that would protect VBA code?
Thankyou
Ed


"Ron de Bruin" wrote:

Hi Ed

You can protect your VBA code in the VBA editior
Alt-F11
ToolsVBAproject properties


--
Regards Ron de Bruin
http://www.rondebruin.nl



"Ed" wrote in message ...
On my spreadsheet I check "Lock" for all cells. Then turn on the
"Protection" for the sheet. In this condition, no one can enter or change
any information in any of the cells. Also you cannot right click a Macro
control button and edit the Macro. This is great.

However, my Macro controls the operation of the spreadsheet.
When you click start, the operation begins and repeats the operation over
and over again continuously without stopping until you press "ESC". When you
press "ESC", the operation stops, as it should. Now in this stopped
condition, a window appears on the screen which (amoung other buttons)
contains the button "Debug".
Even when the Protection is on, you can click this button and it gives you
access to the Macro contents. You can change anything you want to, it is not
Protected.
Is there a way to Protect the contents of the Macro by preventing any access
when you click the "Debug" button?

I would appreciate any help you can give.
Thankyou
Ed




  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default I want the macros to be locked up when cells are locked up.

There is not code associated with it. It is an option you select.

Also, you need look at the EnableCancelKey property to have better control
in your macro. You can then have code execute that will avoid the debug
message and exit more gracefully.

--
Regards,
Tom Ogilvy

"Ed" wrote in message
...
Hi Ron
Thanks for the response.
I looked at the "Tools VBAproject Properties" and am unable to figure

out
what the coding would be.
Could you give me sample entries that would protect VBA code?
Thankyou
Ed


"Ron de Bruin" wrote:

Hi Ed

You can protect your VBA code in the VBA editior
Alt-F11
ToolsVBAproject properties


--
Regards Ron de Bruin
http://www.rondebruin.nl



"Ed" wrote in message

...
On my spreadsheet I check "Lock" for all cells. Then turn on the
"Protection" for the sheet. In this condition, no one can enter or

change
any information in any of the cells. Also you cannot right click a

Macro
control button and edit the Macro. This is great.

However, my Macro controls the operation of the spreadsheet.
When you click start, the operation begins and repeats the operation

over
and over again continuously without stopping until you press "ESC".

When you
press "ESC", the operation stops, as it should. Now in this stopped
condition, a window appears on the screen which (amoung other

buttons)
contains the button "Debug".
Even when the Protection is on, you can click this button and it gives

you
access to the Macro contents. You can change anything you want to, it

is not
Protected.
Is there a way to Protect the contents of the Macro by preventing any

access
when you click the "Debug" button?

I would appreciate any help you can give.
Thankyou
Ed






  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default I want the macros to be locked up when cells are locked up.

Hi Ed

Om the protection tab fill in a password (two times) and mark "Lock project for viewing".
Then Save/Close/reopen the file

You can't do this with code (it is possible with Sendkeys but this is not reliable)


--
Regards Ron de Bruin
http://www.rondebruin.nl



"Ed" wrote in message ...
Hi Ron
Thanks for the response.
I looked at the "Tools VBAproject Properties" and am unable to figure out
what the coding would be.
Could you give me sample entries that would protect VBA code?
Thankyou
Ed


"Ron de Bruin" wrote:

Hi Ed

You can protect your VBA code in the VBA editior
Alt-F11
ToolsVBAproject properties


--
Regards Ron de Bruin
http://www.rondebruin.nl



"Ed" wrote in message ...
On my spreadsheet I check "Lock" for all cells. Then turn on the
"Protection" for the sheet. In this condition, no one can enter or change
any information in any of the cells. Also you cannot right click a Macro
control button and edit the Macro. This is great.

However, my Macro controls the operation of the spreadsheet.
When you click start, the operation begins and repeats the operation over
and over again continuously without stopping until you press "ESC". When you
press "ESC", the operation stops, as it should. Now in this stopped
condition, a window appears on the screen which (amoung other buttons)
contains the button "Debug".
Even when the Protection is on, you can click this button and it gives you
access to the Macro contents. You can change anything you want to, it is not
Protected.
Is there a way to Protect the contents of the Macro by preventing any access
when you click the "Debug" button?

I would appreciate any help you can give.
Thankyou
Ed








  #6   Report Post  
Posted to microsoft.public.excel.programming
Ed Ed is offline
external usenet poster
 
Posts: 279
Default I want the macros to be locked up when cells are locked up.

Hi Ron
Problem solved. It was so simple.
Thankyou again.
Ed

"Ron de Bruin" wrote:

Hi Ed

Om the protection tab fill in a password (two times) and mark "Lock project for viewing".
Then Save/Close/reopen the file

You can't do this with code (it is possible with Sendkeys but this is not reliable)


--
Regards Ron de Bruin
http://www.rondebruin.nl



"Ed" wrote in message ...
Hi Ron
Thanks for the response.
I looked at the "Tools VBAproject Properties" and am unable to figure out
what the coding would be.
Could you give me sample entries that would protect VBA code?
Thankyou
Ed


"Ron de Bruin" wrote:

Hi Ed

You can protect your VBA code in the VBA editior
Alt-F11
ToolsVBAproject properties


--
Regards Ron de Bruin
http://www.rondebruin.nl



"Ed" wrote in message ...
On my spreadsheet I check "Lock" for all cells. Then turn on the
"Protection" for the sheet. In this condition, no one can enter or change
any information in any of the cells. Also you cannot right click a Macro
control button and edit the Macro. This is great.

However, my Macro controls the operation of the spreadsheet.
When you click start, the operation begins and repeats the operation over
and over again continuously without stopping until you press "ESC". When you
press "ESC", the operation stops, as it should. Now in this stopped
condition, a window appears on the screen which (amoung other buttons)
contains the button "Debug".
Even when the Protection is on, you can click this button and it gives you
access to the Macro contents. You can change anything you want to, it is not
Protected.
Is there a way to Protect the contents of the Macro by preventing any access
when you click the "Debug" button?

I would appreciate any help you can give.
Thankyou
Ed






  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 14
Default I want the macros to be locked up when cells are locked up.

Thank You All
It solved the same problem for me.

BobCarter
Douglas, MA

"Ed" wrote:

Hi Ron
Problem solved. It was so simple.
Thankyou again.
Ed

"Ron de Bruin" wrote:

Hi Ed

Om the protection tab fill in a password (two times) and mark "Lock project for viewing".
Then Save/Close/reopen the file

You can't do this with code (it is possible with Sendkeys but this is not reliable)


--
Regards Ron de Bruin
http://www.rondebruin.nl



"Ed" wrote in message ...
Hi Ron
Thanks for the response.
I looked at the "Tools VBAproject Properties" and am unable to figure out
what the coding would be.
Could you give me sample entries that would protect VBA code?
Thankyou
Ed


"Ron de Bruin" wrote:

Hi Ed

You can protect your VBA code in the VBA editior
Alt-F11
ToolsVBAproject properties


--
Regards Ron de Bruin
http://www.rondebruin.nl



"Ed" wrote in message ...
On my spreadsheet I check "Lock" for all cells. Then turn on the
"Protection" for the sheet. In this condition, no one can enter or change
any information in any of the cells. Also you cannot right click a Macro
control button and edit the Macro. This is great.

However, my Macro controls the operation of the spreadsheet.
When you click start, the operation begins and repeats the operation over
and over again continuously without stopping until you press "ESC". When you
press "ESC", the operation stops, as it should. Now in this stopped
condition, a window appears on the screen which (amoung other buttons)
contains the button "Debug".
Even when the Protection is on, you can click this button and it gives you
access to the Macro contents. You can change anything you want to, it is not
Protected.
Is there a way to Protect the contents of the Macro by preventing any access
when you click the "Debug" button?

I would appreciate any help you can give.
Thankyou
Ed






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
Locked worksheet & hyperlinks (w/ select locked cells unchecked) dgold82 Excel Discussion (Misc queries) 1 July 10th 09 09:42 PM
Macros to cells, formula only not data locked Margo Excel Worksheet Functions 4 November 3rd 07 12:22 PM
Macros to protect worksheet and prevent locked cell selection Excel Enthusiastic[_2_] Excel Discussion (Misc queries) 1 April 23rd 07 09:44 AM
Put comments on a locked spreadsheet even though cells not locked RDP Excel Worksheet Functions 1 September 11th 05 11:59 PM
Can macros alter locked cells in excel? nigelbellamy[_2_] Excel Programming 1 January 16th 04 10:22 AM


All times are GMT +1. The time now is 01:42 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"