Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
File Protect using Word Automation
Message
De
10/06/2003 12:04:09
Kathy Wilson
Naval Surface Warfare Center
Crane, Indiana, États-Unis
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
File Protect using Word Automation
Divers
Thread ID:
00798443
Message ID:
00798443
Vues:
249
I need to protect a document created using Word Automation. Users should be able to view the document but not be allowed to make any changes to it. I don't want to allow them to open it as read-only and do a File, Save As either. I have tried the following but receive 'ToolsProtectDocument statement is currently disabled.'

THISFORM.oWord.ActiveDocument.PROTECT(2,.F.,"password")

When I open the document in Word, and select Tools, Protect Document, Protect Document for; Tracked Changes and Comments are both enabled and selectable. However, Forms is disabled. Can anyone let me know how to enable the Forms option using automation?

I have tried using THISFORM.oWord.ActiveDocument.UNPROTECT and was informed that the file was not protected.

I am working with VFP6.0 and '98. I have the same results when trying this with VFP7.0 and '98.

Thanks for your help!

Kathy
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform