Hello again all. I am trying to figure out a way to implement password protection on documents that a program I am working on creates. They should remain with the document regardless of where it is copied to or sent. I will probably also use it to encrypt the contents of the file, but that is another topic.

Here is a rough sequence of events:
1. Application Opens (no document loaded).
2. User opens document with extension registered to application.
(could also be # 1 if they clicked on the document directly)
3. Application Security checks document for security and prompts if necessary.
4. If prompted, user enters password.
5. Application checks password.
6. If passed, document opens, otherwise user is notified of failure.

Hopefully I have been pretty clear about what I am trying to do. It should also not require any server validation or database type checking. I know it is done in like Excel, Word, and other applications.

Thanks in advance!!

D