## WD: LockDocument 0 Doesn't Unlock Subdocument w/ Author Mismatch

Q116473

The information in this article applies to:

- Microsoft Word for Windows, versions 6.0, 6.0a, 6.0c
- Microsoft Word for Windows NT, version 6.0
- Microsoft Word for Windows, versions 7.0, 7.0a
- Microsoft Word for the Macintosh, versions 6.0, 6.0.1

## SUMMARY

The "Microsoft Word Developer's Kit" incorrectly states that if you run the WordBasic command LockDocument with the Lock argument set to 0 and the insertion point in the master document, you can remove the locks from all subdocuments of a master document. This is true only if you have protected the document using the LockDocument macro or the Lock Document button on the Master Document toolbar. If any subdocument has been locked by another means, this command fails to unlock the subdocument.

## MORE INFORMATION

A subdocument can be set to read-only (locked) by the author. A subdocument may also be marked read-only by the system if the author name for the master document and subdocument do not match. In these cases, the "LockDocument 0" command has no impact on the subdocument's read-only status.

## REFERENCES

"Microsoft Word Developer's Kit," version 6.0, page 559
"Microsoft Word Developer's Kit, Third Edition", page 624
"Microsoft Word User's Guide," version 6.0, pages 541, 544
Online Help topic "Locking or unlocking a master document or a subdocument"

Additional query words: subdoc docerr protected

Keywords : kbmacro kbdtacode wordnt winword ntword macword word6 word7 word95
Issue type :
Technology :

Last Reviewed: November 4, 2000 © 2001 Microsoft Corporation. All rights reserved. Terms of Use.