View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.programming
STEVE BELL STEVE BELL is offline
external usenet poster
 
Posts: 692
Default Scenario If Date is greater

A number of people do the following:

1. Set a protection password for the VBE in the workbook
This prevents the user from messing with the code
2. Set the close event to cycle through all sheets and set them to .Visible
= xlSheetVeryHidden
all sheets except one sheet with the Message that workbook will not
work without Macros.
This hides all useful worksheets.
3. Set the open event to unhide all sheets and hide the message sheet.
This makes the worksheets visible only if Macros are enabled.


--
steveB

Remove "AYN" from email to respond
"JavyD" wrote in message
...
I just realized something. If I send this out right, most users will
disable
the macro or the excel application will automatically disable it for them
right. Then the Open Work book event wont work, or I'm I wrong?

"STEVE BELL" wrote:

Hope it works for you.

There may be other ways.

One thing I use is a workbook open event that protects everysheet so that
the user can only select unprotected cells. But any cell can be changed
through code.
I would be easy to modify this to do that kind of protection and after a
certain date it could start restricting things.

--
steveB

Remove "AYN" from email to respond
"JavyD" wrote in message
...
Hmm, that sounds like an idea. Let me look into that, I may be back in
here
for a little vba help, havnt done any in a while. Thanks again Steve.

"STEVE BELL" wrote:

You can create a workbook open event with code that says
(this is not valid code - just the idea)

if Date mydate then
mysheet.mycolumn.protection = true
mysheet.protect password = "stayout"
end if

you can record code to get a better idea of what to write.
and you may need to unprotect the sheet first.
--
steveB

Remove "AYN" from email to respond
"JavyD" wrote in message
...
Hello everyone, long time no see.

A light bulb just went off in my head. But I tryed to make it work
and
the
Scenario only gave me the option to place it on 32 cells. I need it
placed
in 2500. This is what I need.

There's a month, Jan for instance, as a column, and there are
projections
right under it for what is expected to sell in Jan. Well, I dont
want
Jan's
forecast changed after a specific date. Is that possible, without
have
to
lock that month and having to send out the spreadsheet every month.
It's
over 200 spreadsheets.

Let me know, thanks guys.