View Single Post
  #12   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default Disabling macros is not an option!

How could the user open the workbook with no menus. and for any workbook
that is opened (given you leave that option), the user could disable the
macros - that has nothing to do with menus. That is a security setting - or
the user can hold down the shift key. If you actually meant how could the
user print, there are short cuts to allow that - but since macros have been
disabled, the menus are never altered.

Of course, regardless of any steps, the user can print a file using Drag and
Drop by putting a print Icon on the desktop and dragging the file from
windows explorer to the icon and dropping it. then select print in the
dialog. (tested with win98 SE but I would expect all the operating systems
to support this - if not the properties for the xls extension could be
altered to do it on a click). Doubt there is much control one has there,
but haven't played with it.

--
Regards,
Tom Ogilvy



"filo666" wrote in message
...
you're right tom, but think about this, if the programmer leaves the
Application.commandbars("Worksheet Menu Bar").enabled=true (and I mean he
leave excel with no bars in it) how does the user could disabled the
macros???????
try it.

"Tom Ogilvy" wrote:

"Enabled" should of course be "Disabled". My Typo.

--
Regards,
Tom Ogilvy

"Tom Ogilvy" wrote in message
...
I was under the impression that the beforeprint event doesn't run when
macros are enabled. Since the OP stated that disabling macros was the

root
of the whole problem, how would you see this being a solution?

--
Regards,
Tom Ogilvy

"Jim Thomlinson" wrote in

message
...
A possible solution might be to set a flag on a sheet which is very
hidden.
The user can not get to the very hidden sheet (providing the project

is
password protected) so you can control how often a sheet can be

printed.
You
will probably want to use the before print event to check the very

hidden
sheet to determine if the sheet can be printed...

HTH

"Paul Wagstaff" wrote:

Hi folks

Office 97 & NT4

I've been handed a bit of a poisened chalice & like a fool I've

taken
a
sip...so here's the problem:

Esentially I need to prohibit printing a file unless a small

number of
fields are completed. This was originally done in MS Word, but

nothing
stops
the users from choosing 'Disable Macros' and printing out as many

copies
as
they like.

I've come across XML macros that cannot be disabled, so I think

Excel
is
my
only choice (yes?). What I'd like to do then is create a

spreadsheet
that
contains some text fields, which are validated and upon

completion,
prompt
the user to print. I can handle the validation & the final msgbox

"print
now?" etc, but am completely stumped re. creating code from

previous
versions of Excel.

Can anyone help me or suggest an alternative way to solve this

problem?
I
don't mind how it's done as long as users can't print a (partially

or
totally) incomplete form - that's the nub of the issue

Ideally I'd like to use Word, and not use UserForms, but beggars

can't
be
choosers.

Thanks,
Paul