Time Out VBA Code Office 11

J

janine_docsonline

Looking to set up trial period lock out code for Word .dot and .doc on file
New, file Open and whatever else and throw message to screen saying contact
details please register.

I also need to allow option to give password and let the template know it is
accessible without always having to supply fresh templates?

Any suggestions as to how best to achieve this would be great.

Many tks
Janine
 
J

Jezebel

janine_docsonline said:
Looking to set up trial period lock out code for Word .dot and .doc on
file New, file Open and whatever else and throw message to screen saying
contact details please register.

I assume what you're getting at here is that you want documents and
templates that can be used only for a limited time, until the user
registers. Forget it. Find some other way to collect payment. It is
possible, just, to enable/disable an add-in with full security -- but even
that is quite tricky -- but you can't start screwing around with other
people's New and Open commands. Apart from it being antisocial, it won't
work anyway.

I also need to allow option to give password and let the template know it
is accessible without always having to supply fresh templates?

I have not the faintest idea what this question is about. What are fresh
templates?
 
J

janine_docsonline

Not quite what I mean Jezebel so put your claws back where they came from.
It is so the correct code free templates can be downloaded on expiry.
 
J

Jay Freedman

Given the number of questions in the newsgroup from people trying to
protect their intellectual property from being copied [answer: it
can't be done effectively in Word unless you subscribe to Microsoft's
IRM service], I think Jezebel could be forgiven for assuming your
mention of a "trial period lock out code" referred to that. I thought
the same thing.

If you write macros in your template and give them the specific names
that intercept the built-in commands
(http://www.word.mvps.org/FAQs/MacrosVBA/InterceptSavePrint.htm), each
one can compare the system date (the result of the function Now()) to
some predetermined "expiration date" (which you can store in a
document variable or a .txt file or in the registry during
installation); if the system date is later, display a messagebox.
Either way, then call the built-in function that was intercepted.

The code project in the template can be password protected, so the
code can't be viewed. The only ways the message could be avoided are
to remove the template from the system or disable all macros. If you
meant something else by the reference to a password, please explain.

--
Regards,
Jay Freedman
Microsoft Word MVP
Email cannot be acknowledged; please post all follow-ups to the
newsgroup so all may benefit.
 
J

janine_docsonline

Thank you Jay. The form won't have much IP I just want to develop a good
time out code and was looking for ideas so I can collaborate more
effectively with another programmer.

Again thank you.

Given the number of questions in the newsgroup from people trying to
protect their intellectual property from being copied [answer: it
can't be done effectively in Word unless you subscribe to Microsoft's
IRM service], I think Jezebel could be forgiven for assuming your
mention of a "trial period lock out code" referred to that. I thought
the same thing.

If you write macros in your template and give them the specific names
that intercept the built-in commands
(http://www.word.mvps.org/FAQs/MacrosVBA/InterceptSavePrint.htm), each
one can compare the system date (the result of the function Now()) to
some predetermined "expiration date" (which you can store in a
document variable or a .txt file or in the registry during
installation); if the system date is later, display a messagebox.
Either way, then call the built-in function that was intercepted.

The code project in the template can be password protected, so the
code can't be viewed. The only ways the message could be avoided are
to remove the template from the system or disable all macros. If you
meant something else by the reference to a password, please explain.

--
Regards,
Jay Freedman
Microsoft Word MVP
Email cannot be acknowledged; please post all follow-ups to the
newsgroup so all may benefit.

Not quite what I mean Jezebel so put your claws back where they came from.
It is so the correct code free templates can be downloaded on expiry.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top